Function to find the given number is a power of 2 or not?
Answer Posted / sheikh rasel
#include<stdio.h>
main()
{
int i;
if(i%2=0)
printf("The given number is a power of 2");
else
printf("The given number is not a power of 2");
return 0;
}
| Is This Answer Correct ? | 6 Yes | 133 No |
Post New Answer View All Answers
Describe how arrays can be passed to a user defined function
Is c is a middle level language?
write a program that declares an array of 30 elements named "income" in the main functions. then cal and pass the array to a programmer-defined function named "getIncome" within the "getIncome" function, ask the user for annual income of 30 employees. then calculate and print total income on the screen using the following function: "void getIncome ( ai []);
What type of function is main ()?
What is extern c used for?
Implement bit Array in C.
How can I recover the file name given an open stream?
What is stack in c?
Can you please compare array with pointer?
Write a program on swapping (100, 50)
What is a volatile keyword in c?
What is table lookup in c?
Difference between macros and inline functions? Can a function be forced as inline?
What does c value mean?
What are the advantages of c language?