09-05-2022, 07:23 PM
Good job again! Nullo problemo!
The bit rotations are similar to the shift operators, where is the concrete difference?
The bit rotations are similar to the shift operators, where is the concrete difference?
Code: (Select All)
'Uebung mit Bitrotation - 5. Sept. 2022
'Aehnelt den Schiebeoperatoren
Dim As Long a, b
Print
Input "a: ", a
Input "b: ", b
'Verschiebt 1 Bit nach rechts. Entspricht: Zahl / 2
a = _RoR(a, 1)
Print
Print a
'Verschiebt nach links. Entspricht: Zahl * 2
b = _RoL(b, 1)
Print
Print b
'Vierfach des letzten Wertes (b X 4)
b = _RoL(b, 2)
Print
Print b
End