how to write a program in qbasic to find sum of 100 natural numbers
please help
I'm in need guys
Answers
Answered by
49
WAP for find sum of natural numbers from 1 to 100
(If you wanna raise the quantity then type the quantity in 1 to 100 space)
DECLARE SUB SERIES ( )
CLS
CALL SERIES
END
SUB SERIES
FOR I = 1 TO 100
S = S + I
NEXT I
PRINT “SUM OF ALL NATURAL NUMBERS FROM 1 TO 100=”; S
END SUB
(If you wanna raise the quantity then type the quantity in 1 to 100 space)
DECLARE SUB SERIES ( )
CLS
CALL SERIES
END
SUB SERIES
FOR I = 1 TO 100
S = S + I
NEXT I
PRINT “SUM OF ALL NATURAL NUMBERS FROM 1 TO 100=”; S
END SUB
rahul1432:
Ohh, I am so sorry
Answered by
4
Answer:
Even I dont know
Explanation:
Similar questions