CSharp examples for System:String Endian
Return word where a all bits from (including) the lowest set bit to bit 0 are set.
using System;//from ww w .jav a 2 s .com public class Main{ // Return word where a all bits from (including) the // lowest set bit to bit 0 are set. // Return 0 if no bit is set. public static UInt32 LowestBit01Edge( UInt32 x ) { if( 0 == x ) return 0; return x^(x-1); } }