Find Index of least significant bit set in an Integer. ex. int value is say 10001000 results should be 4.
I think the following code will help!!!!!! #include<stdio.h> main() { int a,count=0; scnaf("%d",&a); while(a) { if(a&1==1) { printf("%d",++count); break; } a=a>>1; ++Count; } return; }