answersLogoWhite

0

start

input A & B

if A>B print A is greatest

if B>A print B is greatest

stop

james ola writes.....SOT.

User Avatar

Wiki User

12y ago

What else can I help you with?

Continue Learning about Engineering

Draw a flowchart to accept 3 numbers and display the largest number?

draw a flowchart to display the first tenth even number


An assembly language program that will take three decimal input and display minimum of them?

program that take three decimal number as input and find the largest among them in assembly language


Write a program in COBOL to find the largest of N number?

identification division. program-id. greatest. environment division. data division. working-storage section. 77 a pic 999. 77 b pic 999. 77 c pic 999. procedure division. greatest. display "ENTER THE THREE NUMBERS:". accept a. accept b. accept c. if a > b and a > c display a "is greatest" else if b > c display b "is greatest" else display c "is greatest". display " thank you". stop run.


How do you write a program that generates three random numbers and prints the largest?

For this you need two variables, a and b. Generate the first number and assign it to a. Generate the second and assign it to b. If b is greater than a, assign b to a. Generate the third number and assign it to b. If b is greater than a, assign b to a. Print a. A better method is to use the following function to determine the largest of any two values: int max (int x, int y) { return x>y ? x : y; } Once you know the largest of any two values you can easily determine the largest of any three values with a nested call: int max_of_three (int a, int b, int c) { return max (max (a, b), c)); } Note that we determine the largest of a and b first and then pass that value to a second call along with c, thus establishing the largest of all three. To determine the largest of n values, store the numbers in an array and pass the array and its length to this function: int max_of_n (int a[], size_t n) { int m = a[0]; // store first value while (--n) if (a[n]>m) m=a[n]; // update m whenever a[n] is greater return m; }


Design an algorithm to determine the largest element in a list?

Assume the first element is the largest and store its value. Then traverse the remainder of the list, one element at a time. If the current element's value is larger than the stored value, overwrite the stored value with the current element's value. Once you've traversed the list, the stored value will hold the largest value.

Related Questions

Draw a flowchart to accept 3 numbers and display the largest number?

draw a flowchart to display the first tenth even number


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.


Draw the flowchart of getting the largest number among the three input number?

Ako budoy xd hahahahaahha


Draw the flowchart of getting the largest number among the three?

To create a flowchart for finding the largest number among three numbers (let's call them A, B, and C), start with a "Start" symbol. Then, use a decision symbol to compare A and B; if A is greater, compare A with C in the next decision. If A is still greater, output A as the largest; otherwise, output C. If B is greater than A, compare B with C; if B is greater, output B; otherwise, output C. Finally, end the flowchart with an "End" symbol.


Write an algorithm to find the largest number amongst three numbers and draw a flowchart?

Step1- Read a,b,c. Step2-if a>b continue step 5. Step3- b>c then print “b is the largest " and continue step 7. Step4- continue step 6 Step5-if a>c then print “a is the largest " then continue step7. Step6- print “z is largest". Step7- end.


Can you determine the largest number?

The largest number possible is infinity


What is the highest square number on a calculator?

It depends on the type of calculator you have. If you have a 8-digit calculator, the largest square number you can display is 99,980,001. If you have a 10-digit calculator, the largest square number you can display is 9,999,800,001. With a TI-84, you can display 9.999999999e99 (which is actually rounded).


Where is the largest buck on display?

U.S. states of Pennsylvania (The County_seatis Doylestown)


Largest and smallest vacuum fluorescent display ever made?

cool


Is a karyotype an organized display of an organism's chromosomes?

Yes, a karyotype is a display of an organism's chromosomes (generally in homologous pairs from largest to smallest).


Is avogadro's number the largest constant?

As far as I can determine, it is the largest magnitude constant.


Write an algorithm to read two numbers then display the largest?

Read 2 numbers. If first is larger than second, display second, else display first. That's for the smallest. For the largest reverse the two. For each of the other two, it's easier to just create a variable, call it largest. Initialize it to a very small number, say -1. As you read each number, compare it to largest. If the number is larger than largest, set largest equal to the number. When you finish each list of numbers, then print largest. Best answer Read 2 numbers. If first is larger than second, display second, else display first. That's for the smallest. For the largest reverse the two. For each of the other two, it's easier to just create a variable, call it largest. Initialize it to a very small number, say -1. As you read each number, compare it to largest. If the number is larger than largest, set largest equal to the number. When you finish each list of numbers, then print largest.