grthtrhthjhtyjytjytkergtrhtrjytjerhrfh4:24 29/09/2026ó Þ¯\w•Ùýãóð•SrSSKJrJr /SQr"SS\S9r"SS\5r\R\5 "S S \5r \ R\ 5 "S S \ 5r "S S\ 5r \ R\ 5 g)z~Abstract Base Classes (ABCs) for numbers, according to PEP 3141. TODO: Fill out more detailed documentation on the operators.é)ÚABCMetaÚabstractmethod)ÚNumberÚComplexÚRealÚRationalÚIntegralcó •\rSrSrSrSrSrSrg)ré%z“All numbers inherit from this class. If you just want to check if an argument x is a number, without caring what kind, use isinstance(x, Number). ©N)Ú__name__Ú __module__Ú __qualname__Ú__firstlineno__Ú__doc__Ú __slots__Ú__hash__Ú__static_attributes__r óÚ./opt/alt/python313/lib64/python3.13/numbers.pyrr%s†ñð €IðƒHrr)Ú metaclasscóB•\rSrSrSrSr\S5rSr\ \S55r \ \S55r \S5r \S 5r \S 5r\S 5rS rS r\S5r\S5r\S5r\S5r\S5r\S5r\S5r\S5r\S5rSrg)ré9aNComplex defines the operations that work on the builtin complex type. In short, those are: a conversion to complex, .real, .imag, +, -, *, /, **, abs(), .conjugate, ==, and !=. If it is given heterogeneous arguments, and doesn't have special knowledge about them, it should fall back to the builtin complex type as described below. r có•g)zrArDrGrJrNrRrUrXr[rr rrrr9sm†ñð€IàñKóðKòðØñ"óóð"ðØñ"óóð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"òòðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óó"rrcó•\rSrSrSrSr\S5r\S5r\S5r \S5r \SS j5r S r S r \S 5r\S 5r\S5r\S5r\S5r\S5rSr\S5r\S5rSrSrg)ré¬zÌTo Complex, Real adds the operations that work on real numbers. In short, those are: a conversion to float, trunc(), divmod, %, <, <=, >, and >=. Real also provides defaults for the derived operations. r có•[e)zLAny Real can be converted to a native float object. Called for float(self).r#rs rÚ __float__ÚReal.__float__·ó €ô "Ð!rcó•[e)atrunc(self): Truncates self to an Integral. Returns an Integral i such that: * i > 0 iff self > 0; * abs(i) <= abs(self); * for any Integral j satisfying the first two conditions, abs(i) >= abs(j) [i.e. i has "maximal" abs among those]. i.e. "truncate towards 0". r#rs rÚ __trunc__ÚReal.__trunc__¾s €ô"Ð!rcó•[e)z$Finds the greatest Integral <= self.r#rs rÚ __floor__ÚReal.__floor__Ër0rcó•[e)z!Finds the least Integral >= self.r#rs rÚ__ceil__Ú Real.__ceil__Ðr0rNcó•[e)z Rounds self to ndigits decimal places, defaulting to 0. If ndigits is omitted or None, returns an Integral, otherwise returns a Real. Rounds half toward even. r#)rÚndigitss rÚ __round__ÚReal.__round__Õr'rcó•X-X-4$)z�divmod(self, other): The pair (self // other, self % other). Sometimes this can be computed faster than the pair of operations. r r,s rÚ __divmod__ÚReal.__divmod__Þs€ð ‘ ˜t™|Ð,Ð,rcó•X-X-4$)z�divmod(other, self): The pair (other // self, other % self). Sometimes this can be computed faster than the pair of operations. r r,s rÚ __rdivmod__ÚReal.__rdivmod__æs€ð ‘ ˜u™|Ð,Ð,rcó•[e)z)self // other: The floor() of self/other.r#r,s rÚ __floordiv__ÚReal.__floordiv__îr0rcó•[e)z)other // self: The floor() of other/self.r#r,s rÚ __rfloordiv__ÚReal.__rfloordiv__ór0rcó•[e)z self % otherr#r,s rÚ__mod__Ú Real.__mod__ør0rcó•[e)z other % selfr#r,s rÚ__rmod__Ú Real.__rmod__ýr0rcó•[e)zJself < other < on Reals defines a total ordering, except perhaps for NaN.r#r,s rÚ__lt__Ú Real.__lt__rcrcó•[e)z self <= otherr#r,s rÚ__le__Ú Real.__le__ r0rcó*•[[U55$)z(complex(self) == complex(float(self), 0))ÚcomplexÚfloatrs rrÚReal.__complex__s€ä”u˜T“{Ó#Ð#rcó•U7$)z&Real numbers are their real component.r rs rr%Ú Real.realó €ðˆuˆ rcó•g)z)Real numbers have no imaginary component.rr rs rr)Ú Real.imagó€ðrcó•U7$)zConjugate is a no-op for Reals.r rs rrXÚReal.conjugates €àˆuˆ r©N)r rrrrrrrarerhrkrorrrurxr{r~r�r„r‡rr]r%r)rXrr rrrr¬s$†ñð€Iàñ"óð"ð ñ "óð "ðñ"óð"ðñ"óð"ðó"óð"ò-ò-ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ð ñ"óð"ò $ðñóððñóðõrrcóV•\rSrSrSrSr\\S55r\\S55r Sr Sr g)ri$z›To Real, Rational adds numerator and denominator properties. The numerator and denominator values should be in lowest terms, with a positive denominator. r có•[e)z3The numerator of a rational number in lowest terms.r#rs rÚ numeratorÚRational.numerator-s €ô"Ð!rcó•[e)z\The denominator of a rational number in lowest terms. This denominator should be positive. r#rs rÚ denominatorÚRational.denominator3r'rcóX•[UR5[UR5- $)zëfloat(self) = self.numerator / self.denominator It's important that this conversion use the integer's "true" division rather than casting one side to float before dividing so that ratios of huge integers convert without overflowing. )Úintr˜r›rs rraÚRational.__float__=s#€ô�4—>‘>Ó"¤S¨×)9Ñ)9Ó%:Ñ:Ð:rN) r rrrrrr]rr˜r›rarr rrrr$sI†ñð €Ià Øñ"óóð"ðØñ"óóð"õ;rrcó•\rSrSrSrSr\S5rSr\SSj5r \S5r \S 5r \S 5r \S 5r \S 5r\S 5r\S5r\S5r\S5r\S5r\S5rSr\S5r\S5rSrg)r iHzŽIntegral adds methods that work on integral numbers. In short, these are conversion to int, pow with modulus, and the bit-string operations. r có•[e)z int(self)r#rs rÚ__int__ÚIntegral.__int__Qr0rcó•[U5$)z6Called whenever an index is needed, such as in slicing)ržrs rÚ __index__ÚIntegral.__index__Vs €ä�4‹yÐrNcó•[e)a self ** exponent % modulus, but maybe faster. Accept the modulus argument if you want to support the 3-argument version of pow(). Raise a TypeError if exponent < 0 or any argument isn't Integral. Otherwise, just implement the 2-argument version described in Complex. r#)rrMÚmoduluss rrNÚIntegral.__pow__Zs €ô"Ð!rcó•[e)z self << otherr#r,s rÚ __lshift__ÚIntegral.__lshift__er0rcó•[e)z other << selfr#r,s rÚ __rlshift__ÚIntegral.__rlshift__jr0rcó•[e)z self >> otherr#r,s rÚ __rshift__ÚIntegral.__rshift__or0rcó•[e)z other >> selfr#r,s rÚ __rrshift__ÚIntegral.__rrshift__tr0rcó•[e)z self & otherr#r,s rÚ__and__ÚIntegral.__and__yr0rcó•[e)z other & selfr#r,s rÚ__rand__ÚIntegral.__rand__~r0rcó•[e)z self ^ otherr#r,s rÚ__xor__ÚIntegral.__xor__ƒr0rcó•[e)z other ^ selfr#r,s rÚ__rxor__ÚIntegral.__rxor__ˆr0rcó•[e)z self | otherr#r,s rÚ__or__ÚIntegral.__or__�r0rcó•[e)z other | selfr#r,s rÚ__ror__ÚIntegral.__ror__’r0rcó•[e)z~selfr#rs rÚ __invert__ÚIntegral.__invert__—r0rcó*•[[U55$)zfloat(self) == float(int(self)))r‹ržrs rraÚIntegral.__float__�s€ä”S˜“YÓÐrcó•U7$)z"Integers are their own numerators.r rs rr˜ÚIntegral.numerator¡r�rcó•g)z!Integers have a denominator of 1.ér rs rr›ÚIntegral.denominator¦r’rr•)r rrrrrrr¢r¥rNr«r®r±r´r·rºr½rÀrÃrÆrÉrar]r˜r›rr rrr r HsB†ñð €Iàñ"óð"òðó"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ðñ"óð"ò  ðñóððñóórr N)rÚabcrrÚ__all__rrÚregisterrŠrr‹rr ržr rrÚrÕs‰ðñ@÷:(â ?€ô �wò ô(n"ˆfôn"ð`×Ñ�Ôôsˆ7ôsðj‡ � ˆeÔô!;ˆtô!;ôHaˆxôaðF ×Ñ�#Õr