Pages

Saturday, 19 May 2012

program to print Ten Numbers and find out the Highest Number


39/*Write a program to print Ten Numbers and find out the Highest Number*/

#include<stdio.h>
#include<conio.h>
main()
{
int i,num,temp=0;
clrscr();
printf("Enter The Ten Numbers:\n");
scanf("%d",&num);
for(i=0;i<=10;i++);
{
scanf("%d",&num);
if(temp<num)
temp=num;
printf("\nThe Highest Number is:%d",temp);
}
getch();
}


OUTPUT
            Enter The Ten Numbers:
            1 54 2 6 8 9 7 12 5 6
            The Highest Number is: 54

No comments:

Post a Comment