Open Source Your Knowledge, Become a Contributor
Technology knowledge has to be shared and made accessible for free. Join the movement.
This article was originally published on Medium
All the Rust and Python Bitwise operators share the same bitwise operator symbols except the bitwise NOT.
|Bitwise right shift||>>||>>|
|Bitwise left shift||<<||<<|
-2. Rust uses the two’s complement to find the bitwise negation for signed types. Rust’s signed integer types are called the signed two’s complement integer types.
You can use
1 << n to find out exponents of 2.