QBASIC Symbolic Constants

  Blog Desk       September 7, 2019     1247 No Comments

Symbolic Constants

Constants are fixed values (data) that are used in program and they do not change during program execution. Constants are predefined values that do not change during program execution.

Example


CLS 
REM to calculate area of circle 
INPUT "Enter radius in centimeter"; R
CONST PI = 22/7
LET AREA=PI*R^2
PRINT "area of circle = "; AREA; "sq. cm"
End 

Leave a Reply

Your email address will not be published. Required fields are marked *