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
what are enumerations in C
How do you sort filenames in a directory?
Explain modulus operator. What are the restrictions of a modulus operator?
How can I pad a string to a known length?
Explain can the sizeof operator be used to tell the size of an array passed to a function?
The % symbol has a special use in a printf statement. How would you place this character as part of the output on the screen?
hai iam working in sap sd module for one year and working in lumax ind ltd in desp department but my problem is i have done m.b.a in hr/marketing and working sap sd there is any combination it. can you give right solution of my problem. and what can i do?
What is main () in c language?
What is array in c with example?
What's the total generic pointer type?
What does %p mean?
Can the “if” function be used in comparing strings?
Is there a way to jump out of a function or functions?
Who is the main contributor in designing the c language after dennis ritchie?
Which is better pointer or array?