mirror of
https://github.com/erg-lang/erg.git
synced 2025-08-04 18:58:30 +00:00
Update Int.d.er
This commit is contained in:
parent
dd36942256
commit
9ca01b060c
1 changed files with 8 additions and 0 deletions
|
@ -24,6 +24,10 @@
|
|||
assert bin(13) == "0b1101"
|
||||
assert 13.bit_count() == 3
|
||||
'''
|
||||
'''python
|
||||
assert bin(13) == "0b1101"
|
||||
assert (13).bit_count() == 3
|
||||
'''
|
||||
bit_count: (self: .Int) -> Nat
|
||||
'''
|
||||
Number of bits necessary to represent self in binary.
|
||||
|
@ -35,6 +39,10 @@
|
|||
assert bin(37) == "0b100101"
|
||||
assert 37.bit_length() == 6
|
||||
'''
|
||||
'''python
|
||||
assert bin(37) == "0b100101"
|
||||
assert (37).bit_length() == 6
|
||||
'''
|
||||
bit_length: (self: .Int) -> Nat
|
||||
conjugate: (self: .Int) -> .Int
|
||||
from_bytes: (bytes: Bytes, byteorder := {"big", "little"}, signed := Bool) -> .Int
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue