175k views
1 vote
Write a program. in QBAsSIC

a to find product of two numbers
b to calculate sum of two numbers
c to calculate difference between two numbers
computer q qubasic can anybody help me plz​

1 Answer

3 votes

Answer:

The program is as follows:

5 INPUT A,B

6 PROD = A * B

7 PRINT PROD

8 TOTAL = A + B

9 PRINT TOTAL

10 DIFF = A - B

11 PRINT DIFF

12 END

Step-by-step explanation:

This gets input for the two numbers

5 INPUT A,B

This calculates the product

6 PROD = A * B

This prints the calculated product

7 PRINT PROD

This calculates the sum

8 TOTAL = A + B

This prints the calculated sum

9 PRINT TOTAL

This calculates the difference

10 DIFF = A - B

This prints the calculated difference

11 PRINT DIFF

This ends the program

12 END

User Smashing
by
8.7k points

No related questions found

Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.