To Find The Sum of Any Three Numbers (Qbasic)

Simple Program
 CLS
 INPUT "Enter the first number"; a
 INPUT "Enter the Second number"; b
 INPUT "Enter the third number"; c
 s = a + b + c
 PRINT "The sum of the numbers is "; s
 END



Using Sub Procedure
 DECLARE SUB sum (a, b, c)
 CLS
 CALL sum (a, b, c)
 END

 SUB sum (a, b, c)
 INPUT "Enter the first number"; a
 INPUT "Enter the Second number"; b
 INPUT "Enter the third number"; c
 s = a + b + c
 PRINT "The sum of the numbers is "; s
 END SUB