This is a gentle introduction to programming using the computer programming language QBasic (sometimes called QBasic). This introduction is used for a course in computer literacy for students of all majors. Its goal is to show what programming is about using the fundamental features of QBasic.
These are interactive lessons. Each chapter consists of about 20 web pages, and is about the equivalent of one classroom lecture. At the bottom of each page is a question on the material on that page. Answer the question before moving on to the next page.
Nobody learns programming just by reading. Copy the example programs into QBasic, run them, modify them, and play with them. Details on how to do this are in the lessons. With the guidance of these notes, you can use QBasic itself as an interactive "teaching machine". This is very effective.
chapter 00 PREFACE chapter 01 Small Programs chapter 02 Arithmetic Expressions chapter 03 Variables chapter 04 The INPUT Statement chapter 05 Beginning Graphics chapter 06 Loops chapter 07 More about Loops chapter 08 Example Programs with Loops chapter 09 Loop Conditions chapter 10 Decision Making chapter 11 Single-branch IF Statements chapter 12 Logical Expressions chapter 13 String Variables chapter 14 Creating Large Programs chapter 15 More about Program Structure chapter 16 Practice with Program Construction chapter 17 Decisions chapter 18 Many-way Decisions chapter 19 FOR Loops chapter 20 Further about the FOR Statement chapter 21 Nested Loops, and Graphics chapter 22 Arrays chapter 23 Arrays of Numbers chapter 24 Arrays and Loops chapter 25 File Output chapter 26 File Input Appendix A Installing QBasic Appendix B Running QBasic Index