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 |
How should a programmer decide whether to use a macro or a subroutine to accomplish a given logical function
1 Answers R V College of Engineering, University of Jordan,
A combination of multiple keys defined in a physical file or logical file is called a _________ key
What are the other ways to create an object with out calling new keyword in java?
what is different betweet class and interface in java?
2 Answers Microsoft, Sun Microsystems,
sample code for data transfer between two r/2 systems and r/3 systems?
what is the BAM? where we can use it in BizTalk server?
How to call a C++ function which is compiled with C++ compiler in C code?
how we define two jobs have same name??is it exist??
I would like to know which institute in hyderabad provides best ms-dot net training along with a project. I want to join immediately. please help
Hello all, My name is Nrupali, am a fresher, i know C language beginner. dont have any experience. planning to learn Php. let me know which language should i choose to learn or for salary purpose and growth??? kindly help me to take decision. thanks
Who is providing best mainframes online training in Hyderabad
Mainly Related to Oracle, DBMS , Oracle Stored Procedures, Functions, Oracle 9i Architecture, Redo logs..., Views,
0 Answers Indian Overseas Bank,