Computer Science, asked by rosemaryvarghese2010, 2 months ago

WRITE AN ALGORITHM TO COMPARE TWO NUMBERS AND FIND THE
GREATER ONE

Answers

Answered by TheEnchanted
16

Answer:

Step 1: Start

Step 2: Declare variables a,b and c.

Step 3: Read variables a,b and c.

Step 4: If a>b

If a>c

Display a is the largest number.

Else

Display c is the largest number.

Else

If b>c

Display b is the largest number.

Else

Display c is the greatest number.

Step 5: Stop

Answered by alfiyazahidi
6

step 1- start

step 2- Take two numbers ,n1,n2

step 3- if 1 is greater than 2

step 4- print 1 is the largest number

step5- if 2 is greater than 1

step 6 - print 2 is the largest number

step 7- print 1 is the greater one .

step 8 - stop

Explanation:

phle start karo fir 2 number le lo ap koi sa bhi le sakte ho maine 1 and 2 liya h agar 1 bada h 2 se to print 1 is largest than print 2 if 2 is greater than 1 so , print 2 is the largest one so , print 1 is greater one then stop kar dijiye ❣️ thank you

Similar questions