how to find greatet of 10 numbers without using array?
Answer Posted / aman
int main()
{
int i, num;
int greatest=0;
for(i=0; i<10; i++)
{
scanf("%d", &num);
if(num > greatest)
greatest = num;
}
printf("greatest = %d", greatest);
return 0;
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
c language supports bitwise operations, why a) 'c' language is system oriented b) 'c' language is problem oriented c) 'c' language is middle level language d) all the above
What is the significance of c program algorithms?
What is a structure member in c?
Why shouldn’t I start variable names with underscores?
Some coders debug their programs by placing comment symbols on some codes instead of deleting it. How does this aid in debugging?
What is the time and space complexities of merge sort and when is it preferred over quick sort?
Explain what are run-time errors?
What the advantages of using Unions?
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.
What is the importance of c in your views?
What is the purpose of 'register' keyword in c language?
Does free set pointer to null?
can anyone please tell about the nested interrupts?
What is the difference between union and structure in c?
how to solve "unable to open stdio.h and conio.h header files in windows 7 by using Dos-box software