Follow the below steps to erase the current program:
Few more examples – The following are also strings:
"This is a string"
"1 + 1 = 2"
When a dollar sign ($) is added to the end of a variable, then it is a string.
X$ = "Hello World!"
PRINT 512 (or?512)
Now press F5 to run the program.
The program outputs: 512
2 + 2 (returns 4)
10 - 4 (returns 6)
3 * 34 (returns 102)
x = 5, IF x = 5 THEN PRINT "x equals 5"
Since X does equal 5 in this case, the program outputs:
x equals 5
You can also enter the following statements, instead of the equals sign:
x < 5 (x is less than 5)
x > 5 (x is greater than 5)
Run the following:
x = 16
IF (x > 5) THEN PRINT "x is greater than 5"
x is greater than 5
Run the following example program:
Output (notice how PRINT "2" is skipped):
FOR x = 1 TO 5
IF (x = 2) THEN EXIT FOR
Programming in QBASIC
Deleting the program
The IF and THEN commands
Labels and the GOTO and GOSUB commands
Who was the first Scientist to develop QBASIC?
A quantity that does not change its value during the execution of the program is called as _______?
Which of the following are not allowed in a numeric constant?
It consists of sequence of characters which must be enclosed by quotation mark. It is known as _______?
A data type that cannot be used for mathematical operations is?
A command or an instruction in Qbasic is called as?
Variables without a dollar sign can?
The arithmetic operator which is used for integer division is _______?
Which of the following is not a reserved word or contain a space?
These are formed from the character of the Qbasic character set. They are known as?
Your Score: 0/10