Get premium membership and access questions with answers, video lessons as well as revision papers.

With aid of a pseudo code, design an algorithm that would: - Prompt the user to enter two number X and Y - Divide X by Y....

      

With aid of a pseudo code, design an algorithm that would:
- Prompt the user to enter two number X and Y
- Divide X by Y. However, if the value of Y is 0, the program should display an error message “Error: Division by zero”.

  

Answers


Kavungya
START
PRINT (“Enter two numbers, X and Y”) Input X, Y
IF Y=0 THEN
PRINT ‘Error: division by zero’
ELSE
Quotient = X/Y
PRINT X, Y, Quotient
END IF
STOP
Kavungya answered the question on April 16, 2019 at 13:12


Next: Define the term equilibrium of a firm
Previous: Draw a flowchart for a program that is to prompt for N numbers, accumulate the sum and them find the average. The output is the...

View More Computer Studies Questions and Answers | Return to Questions Index


Learn High School English on YouTube

Related Questions