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 is the output on the screen? int n; n=printf("my name is %d",printf("kiran %d",printf("kumar"))); printf("\n %d \n",n);
What is the difference between Printf(..) and sprint(...) ?
how can i get output the following... 5 4 3 2 1 4 3 2 1 3 2 1 2 1 1 and 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 plz plz...
15.what is the disadvantage of using macros? 16.what is the self-referential structure? 17.can a union be self-referenced? 18.What is a pointer? 19.What is the Lvalue and Rvalue? 20.what is the difference between these initializations? 21.Char a[]=”string”; 22.Char *p=”literal”; 23.Does *p++ increment p, or what it points to?
How to write a code for random pick from 1-1000 numbers? The output should contain the 10 numbers from the range 1-1000 which should pick randomly, ie ,for each time we run the code we should get different outputs.
how to find your architecture is LittleEndian or BigEndian?
Write a program to print numbers from 1 to 100 without using loop in c?
Explain can you assign a different address to an array tag?
Describe the modifier in c?
What is the difference between functions abs() and fabs()?
#include<stdio.h> main() { int a=1; int b=0; b=++a + ++a; printf("%d %d",a,b); }
how can u print a message without using any library function in c