write a program on c(or)c++(or)java language i.e if i have 5
numbers like (10,24,3,9,15) i want to display highest number
from these numbers
Answers were Sorted based on User's Feedback
Answer / bhavesh gharat
#includ <conio.h>
#include <stdio.h>
void main()
{
int a[]={10,24,3,9,15};
int temp=a[0];
for(int i=1;i<a.length;i++)
{
if(temp<a[i])
{
temp=a[i];
}
}
printf(" higest no="+temp);
}
| Is This Answer Correct ? | 4 Yes | 1 No |
Answer / ashwek
/// Using C++
#include<iostream.h>
#include<conio.h>
int main(){
int arr[]={10,24,3,9,15};
int Max=arr[0];
for(int i=1; i<5; i++)
if(Max < arr[i]){
Max = arr[i];
cout<<"Higest number is = " <<Max;
return 0;
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Diffrence between 2.0,3.0,3.5,4.0. versions of .net?
Why we need new operator in java at the time of object declaration and why not in c++?
why applet is introduced?
how to stop execution of step 3 in a job mainframe
I need to fetch all rows from the table based one field value in the table and later do a condition check if the condition is true I will have to move all the rows present in the data base to output file one else if the condition is not satisfied then move all the records of that field value into another file .Please let me know how to do that
Describe the difference between Interface-oriented, Object-oriented and Aspect-oriented programming
I would like to know what is Intellimatch and some interview questions which could be asked related to Intellimatch.
Which of the following are Java modifiers?
Data structure used to impliment a menu:
What is Negative testing?
can we allocate memory for interface? if no then why?
Is anyone has done the ASP.NET MVC4 workshop course(2 days) from Peers Technologies. Let me know. I need to talk before joining ASP.NET MVC4 training at peers, Hyderabad.