Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Flip the most significant bit in a byte
Message
General information
Forum:
ASP.NET
Category:
Other
Title:
Flip the most significant bit in a byte
Environment versions
Environment:
C# 2.0
Miscellaneous
Thread ID:
01158678
Message ID:
01158678
Views:
64
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.
Next
Reply
Map
View

Click here to load this message in the networking platform