Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Flip the most significant bit in a byte
Message
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Titre:
Flip the most significant bit in a byte
Versions des environnements
Environment:
C# 2.0
Divers
Thread ID:
01158678
Message ID:
01158678
Vues:
65
Given a byte I need to flip the most significant bit on to create another byte.
Something like this:
byte newByte = FlipBit7(oldByte);

What is the most elegant way of doing this?

Thanks,
Einar
Semper ubi sub ubi.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform