Computer Science, asked by jadhavtushar088, 3 months ago

What will be the output of the following QBasic code:

CLS

LET P=1

FOR A=1 TO 5

P=P*A

NEXT A

PRINT P

END

With explanation​

Answers

Answered by SARTHAK2912
0

Answer:

first we have p=1

and values of a are 1.2.3.4.5

p=1*1

next a=2

p=1*2

p=2*3

p=6*4

p=24*5

finally p=120

Similar questions