Answer Posted / santhi perumal
#include<stdio.h>
#include<conio.h>
int main()
{
int number;
int position;
int result;
printf("Enter the Number\n");
scanf("%d",&number);
printf("Enter the Position\n");
scanf("%d",&position);
result = (number >>(position-1));
if(result & 1)
printf("Bit is Set");
else
printf("Bit is Not Set");
}
| Is This Answer Correct ? | 18 Yes | 7 No |
Post New Answer View All Answers
What is the collection of communication lines and routers called?
what is the difference between class and unio?
Is sizeof a keyword in c?
hello freinds next week my interview in reliance,nybody has an idea about it intervew questions..so tell
Write a program to print factorial of given number using recursion?
How many levels of indirection in pointers can you have in a single declaration?
The file stdio.h, what does it contain?
Why functions are used in c?
How are strings stored in c?
What is external variable in c?
What is atoi and atof in c?
What are the key features in c programming language?
what are non standard function in c
What is union and structure?
GIven a sequence of characters. How will you convert the lower case characters to upper case characters. ( Try using bit vector - sol given in the C lib -> typec.h)