How To Grade Using Qbasic - Auxiliary Tech

Breaking

Sunday, October 14, 2018

How To Grade Using Qbasic

QBASIC is one of the easiest programs to learn as a beginner because it contains familiar commands that the others do. So once you master QBASIC, you'll soon find other languages much easier. You might already have QBASIC on your computer, but if you don't, just run a search on the web for QBASIC and you'll be sure to find it free.
And i will be writing on how to grade using Qbasic..


QBASIC is a high level programming language that allows us to write programs. BASIC uses English like words and mathematical symbols to write programs. The programs written in QBASIC need to be converted into machine codes. 

FEATURE OF QBASIC
Some features of QBASIC are listed below:
a. QBASIC does not use technical terminology (word) to write statements.
b. QBASIC automatically checks syntax.
c. QBASIC capitalizes the reserved words.
d. QBASIC keeps the same variable name used in a program to identical form.
e. QBASIC allows you to break lengthy programs into modules.

How To Start  QBASIC
QBASIC programming language consists of two files: QBASIC.EXE and QBASIC.HLP. Normally these files are found in a folder named ‘QBASIC’ which is in drive C:.

To start QBASIC, follow these steps.
  1. Click the Start button.
  2. Point to All Programs and then Accessories.
  3. Select Command Prompt. It displays Command Prompt Window.
  4. To move to the root directory, at DOS prompt, type CD\ and press Enter key.
  5. At C:\> prompt, type CD QBASIC and press Enter key.
  6. At C:\ QBASIC> prompt, type qbasic and press Enter key. It will display QBASIC Welcome Screen.
  7. Press Esc key to get QBASIC Editor Screen.
CLEARING PROGRAM WINDOW
To write a new program you need to remove the previous program from the Program Window. To clear or remove the previous program, follow these steps.
a) Press ALT key.
b) Highlight New option and press Enter key. OR. Press F, N keys.


OPENING AN EXISTING PROGRAM
To open an existing program in the Program Window, follow these steps.
a. Press Alt key.
b. Press F key.
c. Highlight Open command and press Enter key.
d. Select a program file the list of files displayed in the Open Dialog box and press Enter key.

EXITING QBASIC
To exit from the QBASIC, follow these steps.
a. Press ALT key. It will activate menu.
b. Press F or Enter key.
c. Press X or select Exit command under File menu and press Enter key.

How To Grade Using Qbasic
Here are the step to use for grading in Qbasic.. follow the step below

DIM grade AS STRING
DIM score AS INTEGER
CLS
COLOR 5
INPUT "enter score"; score
IF score >= 70 THEN
    PRINT "grade A"
ELSEIF score >= 60 THEN
    PRINT "grade B"
ELSEIF score >= 50 THEN
    PRINT "grade C"
ELSEIF score >= 45 THEN
    PRINT "grade D"
ELSEIF score >= 40 THEN
    PRINT "grade E"; 50
ELSEIF score >= 30 THEN
    PRINT "grade F"
END IF


No comments:

Post a Comment

Contact Form

Name

Email *

Message *