You are on page 1of 1

ALGORITMA PEMROGRAMAN NABILA SELLA AGUSTA

1. Algoritm to finds the average of two numbers start a, b as integer x as double input a, b x (a+b)/2 print x finish 2. Algoritm to change a numeric grade to a letter grade start a as integer if a > 86 then print A else if < 86 then print B else if < 75 then print C else if < 50 then print D else if < 40 then print E end if finish 3. Algorithm to find the largest number start n, number, max as integer input n for i 0 to n o input number o if number > max then o max number o end if end for finish 4. Algorthm to find the largest of 1000 number Start Input number x=0 max =0 while (i<1000) if (max, number (i)) then max = number (i) end if increment (i) end while finish

You might also like