|
LSL16 | ||
Result = LSL16(ValueToShift, Bits) | ||
Parameters: ValueToShift=Value that will be shifted Bits=Number of bits the value will be shifted |
||
Returns: Result = Shifted bits |
||
LSL16 is a logical operator that performs a left bit shift upon the bottom 16 bits of a 32bit integer value. Since the operation is only shifting the bottom word (bottom 16bits) of the integer, the top word will not be affected by the shift. FACTS: * LSL32, LSL16, LSL8, LSR32, LSR16 and LSR8 replicate the sign bit of the value they shift * LSL16(ValueToShift,Bits) is equivalent of result = (ValueToShift and $ffff0000) or ((ValueToShift and $ffff) * 2^Bits) Mini Tutorial: Showing the effect of the logical left shift function. Try different value, or different numbers of bits to shift. Replace LSL16 with LSL32 or LSL8
This example would output.
|
Related Info: | LSL32 | LSL8 | LSR16 | LSR32 | LSR8 | ROL16 | ROL32 | ROL8 | ROR16 | ROR32 | ROR8 : |
|
|||||||||||||||||||||||||||||||||||||||
(c) Copyright 2002 - 2024 - Kevin Picone - PlayBASIC.com |