write the program for maximum of the following numbers?
122,198,290,71,143,325,98
Answer Posted / divya
#inclufe<stdio.h>
Void main()
{
int a[7];
for(i=0;i<=7;i++)
{
printf("Enter the nos");
scanf("%d",&a[i]);
}
for(i=0;i<=7;i++)
{
if(a[i]>a[i+1])
printf("%d",a[i]);
else
if(a[i]<a[i+1])
printf("%d",a[i+]);
else
if(a[i]==a[i+1])
printf("%d",a[i]);
}
getch();
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Explain what is wrong with this statement? Myname = ?robin?;
write a program to display all prime numbers
What is the use of #include in c?
How would you use the functions fseek(), freed(), fwrite() and ftell()?
Write a program to generate random numbers in c?
the maximum length of a character constant can be a) 1 character b) 8 characters c) 256 chaacters d) 125 characters
Are there namespaces in c?
What are the output(s) for the following ? #include char *f() {char *s=malloc(8); strcpy(s,"goodbye")} main() { char *f(); printf("%c",*f()='A'); }
What is New modifiers?
What is wrong in this statement?
code for find determinent of amatrix
Want to know how to write a C program that connects to a MySQL server and checks if the InnoDB plug-in is installed on it. If so, your program should print the total number of disk writes by MySQL.
Why is c so popular?
Is c easy to learn?
the process of defining something in terms of itself is called (or) in C it is possible for the functions to call themselves. A function called a) nested function b) void function c) recursive function d) indifinite function