how to find greatet of 10 numbers without using array?
Answers were Sorted based on User's Feedback
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 ? | 9 Yes | 2 No |
Answer / afreen chitragar
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 ? | 1 Yes | 0 No |
Answer / guest
using ? And & operator wa can find out the soution
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / 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 |
What are inbuilt functions in c?
Write a program to exchange two variaables without temp
dibakar & vekatesh..uttejana here..abt ur reply for in place reversal of linked list..wats p stands for there?
Can a pointer be static?
Program will then find the largest of three numbers using nested if-else statements. User is prompted to enter three numbers. Program will find the largest number and display it on the screen. All three numbers entered by the user are also displayed. If user enters 21, 33, and 5, the output should be as follows: You entered: 21, 33 and 5. The largest number is 33.
I have one doubt. What does below statement mean? #define sizeof(operator) where operator can be int or float etc. Does this statement meaningful and where it can be used?
Can you please explain the difference between syntax vs logical error?
What is the method to save data in stack data structure type?
Is c++ based on c?
What is function prototype in c language?
Which of the following about the C comments is incorrect ? a.commentscan go over multiple lines b.comments can start any where in the line c.a line can contain comments with out any language statements d.comments can occur within comments
Why C language is a procedural language?