Given an unsigned int, I have to implement the following operations :
for rightmost bit simple ans
First Method
unsigned int getFirstSetBit(int n){ return log2(n & -n) + 1;
}
Second Method
unsigned int getFirstSetBit(int n){ return ffs(n);