Python/bit_manipulation
Alexander Pantyukhin 4e6c1c049d
Is power of two (#7936)
* add is power of two

* fix comment

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Deal with negative numbers

* Spelling: negative

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
2022-11-01 18:43:03 +01:00
..
__init__.py Add __init__.py files in all the directories (#2503) 2020-09-28 19:42:36 +02:00
binary_and_operator.py Fix typos in Sorts and Bit_manipulation (#4949) 2021-10-20 16:42:32 +08:00
binary_count_setbits.py added binary_count_trailing_zeros.py (#2557) 2020-11-26 09:27:00 +08:00
binary_count_trailing_zeros.py added binary_count_trailing_zeros.py (#2557) 2020-11-26 09:27:00 +08:00
binary_or_operator.py Fix typos in Sorts and Bit_manipulation (#4949) 2021-10-20 16:42:32 +08:00
binary_shifts.py refactor: Remove unnecessary if else condition (#4307) 2021-04-04 09:30:17 +05:30
binary_twos_complement.py Added binary shifts and twos complement functions to bit manipulation (#4068) 2021-02-23 11:45:00 +05:30
binary_xor_operator.py Fix typos in Sorts and Bit_manipulation (#4949) 2021-10-20 16:42:32 +08:00
count_1s_brian_kernighan_method.py Fix broken links by PR #7277 (#7319) 2022-10-16 15:45:25 +02:00
count_number_of_one_bits.py Update count_number_of_one_bits.py (#7589) 2022-10-24 12:13:39 +02:00
gray_code_sequence.py Add a gray_code_sequence.py file to the bit_manipulation folder (#5038) 2021-11-02 18:13:49 +08:00
highest_set_bit.py Add function for highest set bit location (#7586) 2022-10-26 22:09:23 +02:00
index_of_rightmost_set_bit.py Added algorithm for finding index of rightmost set bit (#7234) 2022-10-30 14:28:27 +01:00
is_even.py check whether integer is even or odd using bit manupulation (#7099) 2022-10-23 19:26:22 +02:00
is_power_of_two.py Is power of two (#7936) 2022-11-01 18:43:03 +01:00
README.md Add README files 1/7 (#5754) 2021-11-04 18:49:36 +08:00
reverse_bits.py add reverse_bits.py (#4120) 2021-01-27 15:54:57 +05:30
single_bit_manipulation_operations.py Bit manipulation: get the bit at a given position (#4438) 2021-05-18 20:24:34 +05:30