Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how to find greatet of 10 numbers without using array?

Answer Posted / aman

int main()
{
int i, num;
int greatest=0;

for(i=0; i<10; i++)
{
scanf("%d", &num);
if(num > greatest)
greatest = num;
}
printf("greatest = %d", greatest);
return 0;
}

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what are enumerations in C

1164


How do you sort filenames in a directory?

1185


Explain modulus operator. What are the restrictions of a modulus operator?

1022


How can I pad a string to a known length?

1038


Explain can the sizeof operator be used to tell the size of an array passed to a function?

1078


The % symbol has a special use in a printf statement. How would you place this character as part of the output on the screen?

1284


hai iam working in sap sd module for one year and working in lumax ind ltd in desp department but my problem is i have done m.b.a in hr/marketing and working sap sd there is any combination it. can you give right solution of my problem. and what can i do?

2129


What is main () in c language?

1135


What is array in c with example?

1278


What's the total generic pointer type?

1061


What does %p mean?

1094


Can the “if” function be used in comparing strings?

1061


Is there a way to jump out of a function or functions?

1107


Who is the main contributor in designing the c language after dennis ritchie?

1012


Which is better pointer or array?

1035