Skip to content

Instantly share code, notes, and snippets.

@Fhernd
Created July 24, 2013 03:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Fhernd/6067902 to your computer and use it in GitHub Desktop.
Save Fhernd/6067902 to your computer and use it in GitHub Desktop.
Demostración uso operador bitwise desplazamiento derecha en C#.
class DesplazamientoDerecha
{
static void Main()
{
byte byte1 = 7;
byte byte2 = (byte)(byte1 >> 2);
Console.WriteLine(byte2); // Imprime: 1 (decimal)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment