Computational Operator in Math -
can't seem figure out "<<" operator is:
11<< 2 44 1<<1 2 10<<2 40
the shift operators, bitwise shift value on left number of bits on right:
the << shifts left , adds zeros @ right end.
the >> shifts right , adds either 0s, if value unsigned type, or extends top bit (to preserve sign) if signed type.
thus,2 << 4 32 , -8 >> 3 -1.
reference: http://www-numi.fnal.gov/offline_software/srt_public_context/webdocs/companion/cxx_crib/shift.html
Comments
Post a Comment