how to find the largest of given numbers in an array
Answer Posted / jvhariharan
void main()
{
int a[10],i,max,m;
pf("enter the range of array");
sf("%d",&m);
pf("enter the values:");
for(i=0;i<m;i++)
{sf("%d",&a[i]);
}
max=a[0];
for(i=1;i<m;i++)
{if(a[i]>max)
{max=a[i];
}}
pf("the max no:%d",max);
}
| Is This Answer Correct ? | 12 Yes | 0 No |
Post New Answer View All Answers
Are polymorphisms mutations?
What causes polymorphism?
What are the three parts of a simple empty class?
What is polymorphism explain its types?
What is class in oop with example?
explain sub-type and sub class? atleast u have differ it into 4 points?
Is enum a class?
what are the realtime excercises in C++?
What is object in oop?
Why do pointers exist?
What is meant by oops concept?
What is a class in oop?
What is polymorphism and its types?
What is stream in oop?
What is polymorphism and example?