Answer Posted / adnan sheikh
int SecondMax(int Array[], int ALength)
{
int Fmax,Smax;
Fmax=Smax=Araay[0];
for (int i = 0; i < ALength; i++)
{
if (Array[i] > Smax){
if (Array[i] < Fmax){
Smax = Array[i];
}
else{
Smax = Fmax;
Fmax = Array[i];
}
}
}
return Smax;
}
| Is This Answer Correct ? | 9 Yes | 8 No |
Post New Answer View All Answers
What is array in c++ example?
What does override mean in c++?
To what does “event-driven” refer?
What c++ is used for?
How many types of classes are there in c++?
What is virtual destructor ans explain its use?
Explain differences between new() and delete()?
Write a c program for binary addition of two 8 bit numbers.
What is istream and ostream in c++?
What is the difference between public and private data members?
What is operators in c++?
What are the steps in the development cycle?
Is c++ double?
What is the use of typedef?
What are the stages in the development cycle?