Answer Posted / sumit kumar
Take the input 5 from keyword :-
#include<stdio.h>
main()
{
int num,pos;
printf("enter the no.:");
scanf("%d",&num);
printf("enter the position:");
scanf("%d",&pos);
if(num & (1<<pos))
{
printf("pos is set");
}
else
{
printf("pos is not set");
}
}
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
Explain what is the benefit of using enum to declare a constant?
What is string length in c?
What is calloc()?
What does *p++ do? What does it point to?
Describe how arrays can be passed to a user defined function
What is difference between scanf and gets?
What is function prototype in c with example?
What are all different types of pointers in c?
What is #include stdlib h?
What are linked lists in c?
What is anagram in c?
Why c language?
Where register variables are stored in c?
Where can I get an ansi-compatible lint?
What are linker error?