Convert a number or string to a long integer, or return 0L if no
arguments are given. If x is floating point, the conversion truncates
towards zero.
If x is not a number or if base is given, then x must be a string or
Unicode object representing an integer literal in the given base. The
literal can be preceded by '+' or '-' and be surrounded by whitespace.
The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to
interpret the base from the string as an integer literal. >>>
int('0b100', base=0) 4L
|
|
|
|
|
|
|
|
|
__coerce__(x,
y)
coerce(x, y) |
|
|
|
|
|
__divmod__(x,
y)
divmod(x, y) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
__index__(...)
x[y:z] <==> x[y.__index__():z.__index__()] |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
a new object with type S, a subtype of T
|
|
|
|
|
|
|
|
|
|
|
__pow__(x,
y,
z=...)
pow(x, y[, z]) |
|
|
|
|
|
|
|
|
|
__rdivmod__(x,
y)
divmod(y, x) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
__rpow__(y,
x,
z=...)
pow(x, y[, z]) |
|
|
|
|
|
|
|
|
|
|
|
|
int
|
|
|
|
|
|
|
|
|
__trunc__(...)
Truncating an Integral returns itself. |
|
|
|
|
int or long
|
bit_length(long)
Number of bits necessary to represent self in binary. |
|
|
|
conjugate(...)
Returns self, the complex conjugate of any long. |
|
|
Inherited from object :
__delattr__ ,
__init__ ,
__reduce__ ,
__reduce_ex__ ,
__setattr__ ,
__subclasshook__
|