/
usr
/
lib64
/
python3.12
/
/usr/lib64/python3.12
mkdir
upload
Name
Size
Mode
Actions
asyncio/
-
0755
rm
collections/
-
0755
rm
concurrent/
-
0755
rm
config-3.12-x86_64-linux-gnu/
-
0755
rm
ctypes/
-
0755
rm
curses/
-
0755
rm
dbm/
-
0755
rm
email/
-
0755
rm
encodings/
-
0755
rm
ensurepip/
-
0755
rm
html/
-
0755
rm
http/
-
0755
rm
importlib/
-
0755
rm
json/
-
0755
rm
lib-dynload/
-
0755
rm
lib2to3/
-
0755
rm
logging/
-
0755
rm
multiprocessing/
-
0755
rm
pydoc_data/
-
0755
rm
re/
-
0755
rm
site-packages/
-
0755
rm
sqlite3/
-
0755
rm
tomllib/
-
0755
rm
unittest/
-
0755
rm
urllib/
-
0755
rm
venv/
-
0755
rm
wsgiref/
-
0755
rm
xml/
-
0755
rm
xmlrpc/
-
0755
rm
zipfile/
-
0755
rm
zoneinfo/
-
0755
rm
__pycache__/
-
0755
rm
abc.py
6538
0644
edit
dl
rm
aifc.py
34211
0644
edit
dl
rm
antigravity.py
500
0644
edit
dl
rm
argparse.py
101155
0644
edit
dl
rm
ast.py
64452
0644
edit
dl
rm
base64.py
20634
0755
edit
dl
rm
bdb.py
33573
0644
edit
dl
rm
bisect.py
3423
0644
edit
dl
rm
bz2.py
11847
0644
edit
dl
rm
calendar.py
25864
0644
edit
dl
rm
cgi.py
34418
0755
edit
dl
rm
cgitb.py
12421
0644
edit
dl
rm
chunk.py
5500
0644
edit
dl
rm
cmd.py
14873
0644
edit
dl
rm
code.py
10962
0644
edit
dl
rm
codecs.py
36870
0644
edit
dl
rm
codeop.py
5908
0644
edit
dl
rm
colorsys.py
4062
0644
edit
dl
rm
compileall.py
20507
0644
edit
dl
rm
configparser.py
53789
0644
edit
dl
rm
contextlib.py
27637
0644
edit
dl
rm
contextvars.py
129
0644
edit
dl
rm
copy.py
8412
0644
edit
dl
rm
copyreg.py
7614
0644
edit
dl
rm
cProfile.py
6555
0755
edit
dl
rm
crypt.py
3913
0644
edit
dl
rm
csv.py
16386
0644
edit
dl
rm
dataclasses.py
62085
0644
edit
dl
rm
datetime.py
268
0644
edit
dl
rm
decimal.py
2805
0644
edit
dl
rm
difflib.py
83368
0644
edit
dl
rm
dis.py
30227
0644
edit
dl
rm
doctest.py
106749
0644
edit
dl
rm
enum.py
81540
0644
edit
dl
rm
filecmp.py
10381
0644
edit
dl
rm
fileinput.py
15714
0644
edit
dl
rm
fnmatch.py
5999
0644
edit
dl
rm
fractions.py
38147
0644
edit
dl
rm
ftplib.py
34735
0644
edit
dl
rm
functools.py
37940
0644
edit
dl
rm
genericpath.py
5572
0644
edit
dl
rm
getopt.py
7488
0644
edit
dl
rm
getpass.py
5990
0644
edit
dl
rm
gettext.py
21320
0644
edit
dl
rm
glob.py
8732
0644
edit
dl
rm
graphlib.py
9648
0644
edit
dl
rm
gzip.py
25402
0644
edit
dl
rm
hashlib.py
9683
0644
edit
dl
rm
heapq.py
23024
0644
edit
dl
rm
hmac.py
8043
0644
edit
dl
rm
imaplib.py
54209
0644
edit
dl
rm
imghdr.py
4398
0644
edit
dl
rm
inspect.py
127125
0644
edit
dl
rm
io.py
3582
0644
edit
dl
rm
ipaddress.py
81414
0644
edit
dl
rm
keyword.py
1073
0644
edit
dl
rm
LICENSE.txt
13936
0644
edit
dl
rm
linecache.py
5800
0644
edit
dl
rm
locale.py
78599
0644
edit
dl
rm
lzma.py
13277
0644
edit
dl
rm
mailbox.py
78911
0644
edit
dl
rm
mailcap.py
9333
0644
edit
dl
rm
mimetypes.py
23037
0644
edit
dl
rm
modulefinder.py
23699
0644
edit
dl
rm
netrc.py
6922
0644
edit
dl
rm
nntplib.py
41087
0644
edit
dl
rm
ntpath.py
30404
0644
edit
dl
rm
nturl2path.py
2374
0644
edit
dl
rm
numbers.py
11467
0644
edit
dl
rm
opcode.py
13174
0644
edit
dl
rm
operator.py
10965
0644
edit
dl
rm
optparse.py
60369
0644
edit
dl
rm
os.py
40821
0644
edit
dl
rm
pathlib.py
51052
0644
edit
dl
rm
pdb.py
70297
0755
edit
dl
rm
pickle.py
66911
0644
edit
dl
rm
pickletools.py
94052
0644
edit
dl
rm
pipes.py
8978
0644
edit
dl
rm
pkgutil.py
18281
0644
edit
dl
rm
platform.py
43388
0755
edit
dl
rm
plistlib.py
28582
0644
edit
dl
rm
poplib.py
14742
0644
edit
dl
rm
posixpath.py
17356
0644
edit
dl
rm
pprint.py
24158
0644
edit
dl
rm
profile.py
23092
0755
edit
dl
rm
pstats.py
29289
0644
edit
dl
rm
pty.py
6137
0644
edit
dl
rm
pyclbr.py
11396
0644
edit
dl
rm
pydoc.py
113508
0755
edit
dl
rm
py_compile.py
7837
0644
edit
dl
rm
queue.py
11496
0644
edit
dl
rm
quopri.py
7183
0755
edit
dl
rm
random.py
34689
0644
edit
dl
rm
reprlib.py
7148
0644
edit
dl
rm
rlcompleter.py
7827
0644
edit
dl
rm
runpy.py
12885
0644
edit
dl
rm
sched.py
6351
0644
edit
dl
rm
secrets.py
1984
0644
edit
dl
rm
selectors.py
19671
0644
edit
dl
rm
shelve.py
8560
0644
edit
dl
rm
shlex.py
13353
0644
edit
dl
rm
shutil.py
56762
0644
edit
dl
rm
signal.py
2495
0644
edit
dl
rm
site.py
23439
0644
edit
dl
rm
smtplib.py
43531
0755
edit
dl
rm
sndhdr.py
7448
0644
edit
dl
rm
socket.py
37815
0644
edit
dl
rm
socketserver.py
28065
0644
edit
dl
rm
sre_compile.py
231
0644
edit
dl
rm
sre_constants.py
232
0644
edit
dl
rm
sre_parse.py
229
0644
edit
dl
rm
ssl.py
50904
0644
edit
dl
rm
stat.py
5485
0644
edit
dl
rm
statistics.py
50227
0644
edit
dl
rm
string.py
11786
0644
edit
dl
rm
stringprep.py
12917
0644
edit
dl
rm
struct.py
257
0644
edit
dl
rm
subprocess.py
88747
0644
edit
dl
rm
sunau.py
18478
0644
edit
dl
rm
symtable.py
12477
0644
edit
dl
rm
sysconfig.py
33773
0644
edit
dl
rm
tabnanny.py
11531
0755
edit
dl
rm
tarfile.py
114250
0755
edit
dl
rm
telnetlib.py
23334
0644
edit
dl
rm
tempfile.py
32386
0644
edit
dl
rm
textwrap.py
19718
0644
edit
dl
rm
this.py
1003
0644
edit
dl
rm
threading.py
59742
0644
edit
dl
rm
timeit.py
13463
0755
edit
dl
rm
token.py
2511
0644
edit
dl
rm
tokenize.py
21570
0644
edit
dl
rm
trace.py
29352
0755
edit
dl
rm
traceback.py
46393
0644
edit
dl
rm
tracemalloc.py
18047
0644
edit
dl
rm
tty.py
2035
0644
edit
dl
rm
types.py
10993
0644
edit
dl
rm
typing.py
118836
0644
edit
dl
rm
uu.py
7341
0644
edit
dl
rm
uuid.py
29656
0644
edit
dl
rm
warnings.py
21909
0644
edit
dl
rm
wave.py
22769
0644
edit
dl
rm
weakref.py
21513
0644
edit
dl
rm
webbrowser.py
24169
0755
edit
dl
rm
xdrlib.py
5942
0644
edit
dl
rm
zipapp.py
7543
0644
edit
dl
rm
zipimport.py
27840
0644
edit
dl
rm
_aix_support.py
4021
0644
edit
dl
rm
_collections_abc.py
32089
0644
edit
dl
rm
_compat_pickle.py
8761
0644
edit
dl
rm
_compression.py
5681
0644
edit
dl
rm
_markupbase.py
14653
0644
edit
dl
rm
_osx_support.py
22023
0644
edit
dl
rm
_pydatetime.py
92087
0644
edit
dl
rm
_pydecimal.py
227283
0644
edit
dl
rm
_pyio.py
93593
0644
edit
dl
rm
_pylong.py
10790
0644
edit
dl
rm
_py_abc.py
6189
0644
edit
dl
rm
_sitebuiltins.py
3128
0644
edit
dl
rm
_strptime.py
28393
0644
edit
dl
rm
_sysconfigdata__linux_x86_64-linux-gnu.py
72132
0644
edit
dl
rm
_threading_local.py
7220
0644
edit
dl
rm
_weakrefset.py
5893
0644
edit
dl
rm
__future__.py
5218
0644
edit
dl
rm
__hello__.py
227
0644
edit
dl
rm
Edit:
/usr/lib64/python3.12/operator.py
(10965B)
""" Operator Interface This module exports a set of functions corresponding to the intrinsic operators of Python. For example, operator.add(x, y) is equivalent to the expression x+y. The function names are those used for special methods; variants without leading and trailing '__' are also provided for convenience. This is the pure Python implementation of the module. """ __all__ = ['abs', 'add', 'and_', 'attrgetter', 'call', 'concat', 'contains', 'countOf', 'delitem', 'eq', 'floordiv', 'ge', 'getitem', 'gt', 'iadd', 'iand', 'iconcat', 'ifloordiv', 'ilshift', 'imatmul', 'imod', 'imul', 'index', 'indexOf', 'inv', 'invert', 'ior', 'ipow', 'irshift', 'is_', 'is_not', 'isub', 'itemgetter', 'itruediv', 'ixor', 'le', 'length_hint', 'lshift', 'lt', 'matmul', 'methodcaller', 'mod', 'mul', 'ne', 'neg', 'not_', 'or_', 'pos', 'pow', 'rshift', 'setitem', 'sub', 'truediv', 'truth', 'xor'] from builtins import abs as _abs # Comparison Operations *******************************************************# def lt(a, b): "Same as a < b." return a < b def le(a, b): "Same as a <= b." return a <= b def eq(a, b): "Same as a == b." return a == b def ne(a, b): "Same as a != b." return a != b def ge(a, b): "Same as a >= b." return a >= b def gt(a, b): "Same as a > b." return a > b # Logical Operations **********************************************************# def not_(a): "Same as not a." return not a def truth(a): "Return True if a is true, False otherwise." return True if a else False def is_(a, b): "Same as a is b." return a is b def is_not(a, b): "Same as a is not b." return a is not b # Mathematical/Bitwise Operations *********************************************# def abs(a): "Same as abs(a)." return _abs(a) def add(a, b): "Same as a + b." return a + b def and_(a, b): "Same as a & b." return a & b def floordiv(a, b): "Same as a // b." return a // b def index(a): "Same as a.__index__()." return a.__index__() def inv(a): "Same as ~a." return ~a invert = inv def lshift(a, b): "Same as a << b." return a << b def mod(a, b): "Same as a % b." return a % b def mul(a, b): "Same as a * b." return a * b def matmul(a, b): "Same as a @ b." return a @ b def neg(a): "Same as -a." return -a def or_(a, b): "Same as a | b." return a | b def pos(a): "Same as +a." return +a def pow(a, b): "Same as a ** b." return a ** b def rshift(a, b): "Same as a >> b." return a >> b def sub(a, b): "Same as a - b." return a - b def truediv(a, b): "Same as a / b." return a / b def xor(a, b): "Same as a ^ b." return a ^ b # Sequence Operations *********************************************************# def concat(a, b): "Same as a + b, for a and b sequences." if not hasattr(a, '__getitem__'): msg = "'%s' object can't be concatenated" % type(a).__name__ raise TypeError(msg) return a + b def contains(a, b): "Same as b in a (note reversed operands)." return b in a def countOf(a, b): "Return the number of items in a which are, or which equal, b." count = 0 for i in a: if i is b or i == b: count += 1 return count def delitem(a, b): "Same as del a[b]." del a[b] def getitem(a, b): "Same as a[b]." return a[b] def indexOf(a, b): "Return the first index of b in a." for i, j in enumerate(a): if j is b or j == b: return i else: raise ValueError('sequence.index(x): x not in sequence') def setitem(a, b, c): "Same as a[b] = c." a[b] = c def length_hint(obj, default=0): """ Return an estimate of the number of items in obj. This is useful for presizing containers when building from an iterable. If the object supports len(), the result will be exact. Otherwise, it may over- or under-estimate by an arbitrary amount. The result will be an integer >= 0. """ if not isinstance(default, int): msg = ("'%s' object cannot be interpreted as an integer" % type(default).__name__) raise TypeError(msg) try: return len(obj) except TypeError: pass try: hint = type(obj).__length_hint__ except AttributeError: return default try: val = hint(obj) except TypeError: return default if val is NotImplemented: return default if not isinstance(val, int): msg = ('__length_hint__ must be integer, not %s' % type(val).__name__) raise TypeError(msg) if val < 0: msg = '__length_hint__() should return >= 0' raise ValueError(msg) return val # Other Operations ************************************************************# def call(obj, /, *args, **kwargs): """Same as obj(*args, **kwargs).""" return obj(*args, **kwargs) # Generalized Lookup Objects **************************************************# class attrgetter: """ Return a callable object that fetches the given attribute(s) from its operand. After f = attrgetter('name'), the call f(r) returns r.name. After g = attrgetter('name', 'date'), the call g(r) returns (r.name, r.date). After h = attrgetter('name.first', 'name.last'), the call h(r) returns (r.name.first, r.name.last). """ __slots__ = ('_attrs', '_call') def __init__(self, attr, *attrs): if not attrs: if not isinstance(attr, str): raise TypeError('attribute name must be a string') self._attrs = (attr,) names = attr.split('.') def func(obj): for name in names: obj = getattr(obj, name) return obj self._call = func else: self._attrs = (attr,) + attrs getters = tuple(map(attrgetter, self._attrs)) def func(obj): return tuple(getter(obj) for getter in getters) self._call = func def __call__(self, obj): return self._call(obj) def __repr__(self): return '%s.%s(%s)' % (self.__class__.__module__, self.__class__.__qualname__, ', '.join(map(repr, self._attrs))) def __reduce__(self): return self.__class__, self._attrs class itemgetter: """ Return a callable object that fetches the given item(s) from its operand. After f = itemgetter(2), the call f(r) returns r[2]. After g = itemgetter(2, 5, 3), the call g(r) returns (r[2], r[5], r[3]) """ __slots__ = ('_items', '_call') def __init__(self, item, *items): if not items: self._items = (item,) def func(obj): return obj[item] self._call = func else: self._items = items = (item,) + items def func(obj): return tuple(obj[i] for i in items) self._call = func def __call__(self, obj): return self._call(obj) def __repr__(self): return '%s.%s(%s)' % (self.__class__.__module__, self.__class__.__name__, ', '.join(map(repr, self._items))) def __reduce__(self): return self.__class__, self._items class methodcaller: """ Return a callable object that calls the given method on its operand. After f = methodcaller('name'), the call f(r) returns r.name(). After g = methodcaller('name', 'date', foo=1), the call g(r) returns r.name('date', foo=1). """ __slots__ = ('_name', '_args', '_kwargs') def __init__(self, name, /, *args, **kwargs): self._name = name if not isinstance(self._name, str): raise TypeError('method name must be a string') self._args = args self._kwargs = kwargs def __call__(self, obj): return getattr(obj, self._name)(*self._args, **self._kwargs) def __repr__(self): args = [repr(self._name)] args.extend(map(repr, self._args)) args.extend('%s=%r' % (k, v) for k, v in self._kwargs.items()) return '%s.%s(%s)' % (self.__class__.__module__, self.__class__.__name__, ', '.join(args)) def __reduce__(self): if not self._kwargs: return self.__class__, (self._name,) + self._args else: from functools import partial return partial(self.__class__, self._name, **self._kwargs), self._args # In-place Operations *********************************************************# def iadd(a, b): "Same as a += b." a += b return a def iand(a, b): "Same as a &= b." a &= b return a def iconcat(a, b): "Same as a += b, for a and b sequences." if not hasattr(a, '__getitem__'): msg = "'%s' object can't be concatenated" % type(a).__name__ raise TypeError(msg) a += b return a def ifloordiv(a, b): "Same as a //= b." a //= b return a def ilshift(a, b): "Same as a <<= b." a <<= b return a def imod(a, b): "Same as a %= b." a %= b return a def imul(a, b): "Same as a *= b." a *= b return a def imatmul(a, b): "Same as a @= b." a @= b return a def ior(a, b): "Same as a |= b." a |= b return a def ipow(a, b): "Same as a **= b." a **=b return a def irshift(a, b): "Same as a >>= b." a >>= b return a def isub(a, b): "Same as a -= b." a -= b return a def itruediv(a, b): "Same as a /= b." a /= b return a def ixor(a, b): "Same as a ^= b." a ^= b return a try: from _operator import * except ImportError: pass else: from _operator import __doc__ # All of these "__func__ = func" assignments have to happen after importing # from _operator to make sure they're set to the right function __lt__ = lt __le__ = le __eq__ = eq __ne__ = ne __ge__ = ge __gt__ = gt __not__ = not_ __abs__ = abs __add__ = add __and__ = and_ __call__ = call __floordiv__ = floordiv __index__ = index __inv__ = inv __invert__ = invert __lshift__ = lshift __mod__ = mod __mul__ = mul __matmul__ = matmul __neg__ = neg __or__ = or_ __pos__ = pos __pow__ = pow __rshift__ = rshift __sub__ = sub __truediv__ = truediv __xor__ = xor __concat__ = concat __contains__ = contains __delitem__ = delitem __getitem__ = getitem __setitem__ = setitem __iadd__ = iadd __iand__ = iand __iconcat__ = iconcat __ifloordiv__ = ifloordiv __ilshift__ = ilshift __imod__ = imod __imul__ = imul __imatmul__ = imatmul __ior__ = ior __ipow__ = ipow __irshift__ = irshift __isub__ = isub __itruediv__ = itruediv __ixor__ = ixor
Save
cmd:
run