can anyone give me a complex activity on qbasic with commands?
Answers
Answer:
I have made a program for a working calculator, here it is !! Enjoy !!
Explanation:
Rem calculator
cls
10
print "input first operand"
input a
print "select operation"
print "addition(a)"
print "subtraction(s)"
print "multiplication(m)"
print "division(d)"
print "exponentification(e)"
print "rooting(r)"
print "Quit(q)"
do
next$ = inkey$
loop until next$ <> ""
gosub input_var2
select case next$
case "a"
c = a + b
print "sum is:";c
case "s" c = a - b
print "Difference is:";c
case "m" c= a*b print "Product is :";c
case "d" c = a/b
print "Quotient is:";c
case "e" c = a^b
print "Exponentification is:"c
case "r" c = a^ 1/b
print "Root is:";c
case "q"
end
end select
sleep 3
goto 10
sub input_var
input "enter second operand";b
end sub
HOPE IT HELPS !!!✌