Find greatest number out of 10 number without using loop.

Answer Posted / dheeraj

#include<stdio.h>
#include<conio.h>
input(int a[]);
find(int []);
int i=0,a[10],j=0,max=0;
main()
{
clrscr();

printf("enter no");
input(a);
find(a);
printf("\nmax no is==%d",max);
}
input(int a[10])
{
i++;
scanf("%d",&a[i]);
if(i<10)
{
input(a);
}
}
find(int a[10])
{

if(j<10)
{
j++;

if(max<a[j])
{
max=a[j];
}
find(a);
}

}

Is This Answer Correct ?    9 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you construct an increment statement or decrement statement in C?

729


what are non standard function in c

1420


What is main () in c language?

582


What is null character in c?

676


Explain b+ tree?

612






#define f(g,h) g##h main O int i=0 int var=100 ; print f ("%d"f(var,10));} wat would be the output??

1529


What is the best style for code layout in c?

620


What is variable and explain rules to declare variable in c?

543


Can main () be called recursively?

617


What is pragma c?

601


What will the code below print when it is executed?   int x = 3, y = 4;         if (x = 4)                 y = 5;         else                 y = 2;         printf ("x=%d, y=%d ",x,y);

1340


What is storage class?

641


The number of bytes of storage occupied by short, int and long are a) 2, 2 and 4 b) 2, 4 and 4 c) 4, 4 and 4 d) none

752


What is NULL pointer?

666


What is the incorrect operator form following list(== , <> , >= , <=) and what is the reason for the answer?

923