Computer Science, asked by rupaavesh38, 15 days ago

Write a QBasic program to print the first 12 multiples of 5 using any loop

Answers

Answered by bozojohnson
0

Answer:

Explanation:

i dont know , loll

Answered by aditijaink283
0

Answer:

The answer to the given question is:

QBasic program to print first 12 multiples of 5 using any loop

DECLARE FUNCTION print_table (n, i)

CLS

INPUT "Enter number : ", n

print_tableof5 (n, 1)

END

FUNC print_tableof5 (n, i)

IF i <= 12 THEN

PRINT n;" * "; i;" = "; n * i

print_tableof5 (n , i + 1)

END IF

END FUNC

Explanation:

The steps to write the code are:

  • First, the program asks the user to enter a number. Given input n.
  • Loop us from i = 1 to 12 and print n * I.

The words IF, THEN and END IF are parentheses that divide the program into branches. It is exactly like the decisions of the previous chapter, but now the only branch is the real branch.

#SPJ3

Similar questions