Abstract

This chapter discusses control statements in the BASIC language. BASIC language can only be expressed with the simplest type of flowchart, which does not contain any decision boxes. The programs that one has been writing so far in BASIC have been purely linear, which imposes considerable limitations on the problems which one can solve at the computer terminal. The next statement to be executed after a GO TO is the statement on the line number written after the words GO TO. Control can be transferred by a GO TO statement forwards or backwards within a program so that the line number referred to in the GO TO statement can be greater or less than the line number of the GO TO statement itself. The program would be abandoned when it was considered that enough numbers had been entered. Care should be taken to ensure that a GO TO statement always refers to an executable statement and not to a directive such as REM and DATA even though many versions of BASIC would automatically transfer control to the next executable statement. Few serious and practical problems can be flowcharted for a computer in a linear manner; such a flow chart will almost certainly contain the diamond shaped boxes and make use of some of the looping or iterative techniques.

Full Text
Paper version not known

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.