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...

Write a code snippets to find greatest and least of any
number of inputs without taking the help of array

Answer Posted / sundar

#include <stdio.h>
#include <conio.h>

void main(void)
{
unsigned int max = 0; unsigned int min = -1;unsigned int
wish = 1;

while(wish)
{
printf("\nEnter The Number sequence ( 0 to terminate ) . .
. ");
scanf("%d",&wish);
if(wish > max) max = wish;
if(wish < min) min = wish;
}
printf(" Max = %u Min = %u ",max,min );
}

Is This Answer Correct ?    4 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

create a .dll component operation and use created component in another project. required methods events and properties. connect, add,search,data report

2458


Write a script to delete all the files in a folder except one desired file.

1280


how exactly is the lngColour used?

2117