Examples
The high bit of a byte
Input
4f2e968b543c835e6648ddcc.bin
2 bytes
DownloadExpected answer
Hexadecimal bytes40 00- Amount
1- Type
Logical shift
An unsigned RGB channel
Input
40754d147de57db8fe80ee4b.bin
3 bytes
DownloadExpected answer
Hexadecimal bytes3f 1f 00- Amount
2- Type
Logical shift
A four-bit nibble
Input
59cee1525d826e6337dd015e.bin
2 bytes
DownloadExpected answer
Hexadecimal bytes00 0f- Amount
4- Type
Logical shift
One-bit flags
Input
4e225601a48925147f919ace.bin
4 bytes
DownloadExpected answer
Hexadecimal bytes00 01 02 04- Amount
1- Type
Logical shift
The sign-bit boundary
Input
517391d5972c2de2db58edb1.bin
2 bytes
DownloadExpected answer
Hexadecimal bytes0f 10- Amount
3- Type
Logical shift
Logical shifts replace the leftmost bits with zeros. Arithmetic shifts preserve the most significant bit (MSB) of the original byte keeping the sign the same (positive or negative).
Format reference: Bit shift right background and specification
Parameters
| Parameter | Default value | Input and choices |
|---|---|---|
| Amount | 1 | Number |
| Type | Logical shift | Logical shift, Arithmetic shift |