Write a program that takes a 5 digit number and calculates
2 power
that number and prints it.
Answer Posted / sushant shrivastava
include<math.h>
include<stdio.h>
int main()
{
int i,num;
printf("Enter the value of i");
scanf("%d",&i)
num=POW(i,2);
printf("%d%d",num);
}
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
Write a C program that will accept a hexadecimal number as input and then display a menu that will permit any of the following operations to be carried out: Display the hexadecimal equivalent of the one's complement. (b) Carry out a masking operation and then display the hexadecimal equivalent of the result. (c) Carry out a bit shifting operation and then display the hexadecimal equivalent of the result. (d) Exit. If the masking operation is selected, prompt the user lor the type of operation (bitwise and, bitwise exclusive or, or bitwise or) and then a (hexadecimal) value for the mask. If the bit shifting operation is selected. prompt the user for the type of shift (left or right), and then the number of bits. Test the program with several different (hexadecimal) input values of your own choice.
Is c language still used?
Who developed c language?
What is the difference between variable declaration and variable definition in c?
What is wrong with this code?
Write a program to generate the Fibinocci Series
What are the two types of structure?
How can I write data files which can be read on other machines with different word size, byte order, or floating point formats?
Write the control statements in C language
How many parameters should a function have?
How are pointers declared in c?
What is the general form of #line preprocessor?
What are comments and how do you insert it in a C program?
"C" language developed by "Dennis Ritchie" at AT & T. his remarks are a) too general, too abstract b) could deal with only specific problems c) lost generality of BCPL and B restored d) no remarks
What is the right way to use errno?