answersLogoWhite

0

void main()

{

int a,b,c;

clrscr();

printf("Enter the value of a:");

scanf("%d",&a);

printf("\nEnter the value of b:");

scanf("%d",&b);

printf("\nEnter the value of c:");

scanf("%d",&c);

if(a>b)

{

if(a>c)

{

if(b>c)

{

printf("c is smallest\n");

printf("b is middle\n");

printf("a is largest\n");

}

else

{

printf("b is smallest\n");

printf("c is middle\n");

printf("a is largest\n");

}

}

else

{

printf("b is smallest\n");

printf("a is middle\n");

printf("c is largest\n");

}

}

else

if(b>c)

{

if(a>c)

{

printf("c is smallest\n");

printf("a is middle\n");

printf("b is largest\n");

}

else

{

printf("a is smallest\n");

printf("c is middle\n");

printf("b is largest\n");

}

}

else

{

printf("a is smallest\n");

printf("b is middle\n");

printf("c is largest\n");

}

getch();

}

User Avatar

Wiki User

13y ago

What else can I help you with?

Related Questions

What is the algorithm to input 3 numbers and output them in ascending order?

To sort three numbers in ascending order, you can use a simple comparison-based algorithm. First, compare the first two numbers and swap them if the first is greater than the second. Then, compare the second number with the third and swap if necessary. Finally, check the first number against the second again to ensure they are in order. This process will yield the numbers in ascending order.


How do you sort numbers ascending in vbs?

To sort numbers in ascending order in VBScript, you can use an array and the built-in Sort method of a Dictionary object. First, store the numbers in an array, then add them to a Dictionary and sort the keys. Finally, you can loop through the sorted keys to retrieve the numbers in ascending order. Here's a simple example: Dim numbers numbers = Array(5, 2, 9, 1, 3) Set dict = CreateObject("Scripting.Dictionary") For Each num In numbers dict.Add num, num Next ' Sort and display For Each key In dict.Keys WScript.Echo key Next This will output the numbers in ascending order.


PHP program to find the minimum number among a list?


What is accuracy of a good program?

It depends on to what level of accuracy you tend to have with the output of your program Accuracy can be treated as: (Desired Output / Actual Output of your Program)


What does program output with input mean?

Program output with input refers to the result produced by a program when it processes specific data or instructions provided as input. The output can be in various forms, such as text, numbers, or visual displays, depending on the program's purpose. Essentially, it illustrates how the program responds to the given input, demonstrating its functionality and behavior. This concept is fundamental in programming, as it helps developers understand the effects of their code and debug any issues.


Which documentation is typically written first input output internal program or external program?

Output documentation


Write a program to find the largest of n numbers in c?

Without Using Arrays Program: #include<stdio.h> main() { int n,m,i,max; printf("How many numbers(n) you going to enter:"); scanf("%d",&n); printf("Enter the numbers:"); scanf("%d",&m); max=m; for(i=2;i<=n;i++) { scanf("%d",&m); if(m>max) max=m; } printf("The Largest Number is %d",max); } Output: How many numbers(n) you going to enter:5 Enter the numbers: 25 410 362 5 56 The Largest Number is 410 With Using Arrays Program: #include<stdio.h> #include<conio.h> void main() { int max_num(int a[],int n); int max,i,n; int a[50]; clrscr(); printf("Enter n number:"); scanf("%d",&n); printf("Enter the numbers:"); for(i=0;i<n;i++) scanf("%d",&a[i]); max=max_num(a,n); printf("The largest number is %d",max); getch(); } int max_num(int a[],int n) { int i,m=0; for(i=0;i<n;i++) { if(a[i]>m) m=a[i]; } return m; } output: Enter n number:10 Enter the numbers: 123 456 789 963 852 147 5 56 600 753 The largest number is 963


What is input -output bound program?

input output bound program is a program (or process in precise way), which spends most of time allocated to it for execution, on input/output devices and need very small CPU time for it.


What is the quantity of output of this equation The numbers are not filled and you have to answer the numbers for the dollar signs and to do this you have to use the quantity of output formula.$$$10?

The answer is the quantity of the two numbers


How do you append a output of a program to a program?

you mean like show some sample output? Just put it in comments at the bottom. Run the program, and in the top left of the command prompt there is a button you can click. Select mark, highlight the output, then select copy. Paste it onto the end of the program.


Can A Computer Output Electricity In Computercraft you can say if true output power on this side Can you say in a program to output power say to light a light So if true then output power to led's?

A Computer Output Electricity in Computercraft cannot be said to make a program to output power, regardless of the side.


How do you Dwraw the flowchart to find the largest of 4 numbers?

To draw a flowchart for finding the largest of four numbers, start with a "Start" symbol, followed by input symbols to read the four numbers (A, B, C, D). Use decision diamonds to compare pairs of numbers: first compare A and B, then compare the larger of those with C, and finally compare that result with D. The flowchart will have output symbols to display the largest number at the end, concluding with an "End" symbol.