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

find largest of 3 no

Answer Posted / guest

#include<stdio.h>
main()
{
int num1,num2,num3,num4,num5;
clrscr();
printf("Please enter five numbers:");
scanf("%i,%i,%i,%i,%i",&num1,&num2,&num3,&num4,&num5);
if(num1>num2,num3,num4,num5)
{
printf("this number is the largest %i",num1);
}
else if(num2>num1,num3,num4,num5)
{
printf("this number is the largest %i",num2);
}
else if(num3>num2,num4,num5,num1)
{
printf("this number is the largest %i",num3);
}
else if(num4>num1,num2,num3,num5)
{
printf("this is the largest number %i",num4);
}
else if(num5>num1,num2,num3,num4)
{
printf("this is the largest number %i",num5);
}
getch();
}


Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why c is called a mid level programming language?

1059


typedef enum { html, java, javascript, perl, cgi } lang;The above statement defines a : a) Union b) User defined type c) Enumerated variable d) none

1191


Write a C/C++ program to add a user to MySQL. The user should be permitted to only "INSERT" into the given database.

1958


1.int a=10; 2.int b=20; 3. //write here 4.b=30; Write code at line 3 so that when the value of b is changed variable a should automatically change with same value as b. 5.

2144


What does struct node * mean?

1001


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

1215


How will you write a code for accessing the length of an array without assigning it to another variable?

1035


What is c standard library?

1190


What are the similarities between c and c++?

1059


Where register variables are stored in c?

952


Explain what header files do I need in order to define the standard library functions I use?

1159


When a c file is executed there are many files that are automatically opened what are they files?

1091


Explain Basic concepts of C language?

1138


What functions are used for dynamic memory allocation in c language?

1134


How would you obtain the current time and difference between two times?

1280