Created
July 24, 2013 02:42
-
-
Save Fhernd/6067721 to your computer and use it in GitHub Desktop.
Demostración de operador desplazamiento a la izquierda (left shift) en lenguaje C#.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class DesplazamientoIzquierda | |
{ | |
static void Main() | |
{ | |
byte byte1 = 7; | |
byte byte2 = (byte)(byte1 << 3); | |
Console.WriteLine(byte2); // Imprime: 56 | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment