How To Run Pascal Programs

Table of contents:

How To Run Pascal Programs
How To Run Pascal Programs

Video: How To Run Pascal Programs

Video: How To Run Pascal Programs
Video: Pascal programming tutorial 2024, May
Anonim

The main problem for a beginner in programming in the Pascal language is the launch of the first program. The Pascal compiler has many functions that can be easily confused.

How to run Pascal programs
How to run Pascal programs

Instructions

Step 1

To start the Turbo Pascal editor program, just run the Turbo.exe file in the bin directory of the installed program. A blue window appears, in which you need to enter the code of the future program. The top bar displays the menu items required to work with the code. To activate this menu, press the F10 key.

Step 2

After writing the program, it should be saved in order to avoid unforeseen situations. To do this, you need to go to the corresponding menu item. To do this, press the F10 key on the keyboard, select the File - Save tab, after which the file save menu will open. After assigning a name to the program, press the Enter key. The file is saved. The required file is opened in the same way (key F10 - File - Open).

Step 3

To test a written program and run it, you must first compile it. To start compilation, use the key combination alt="Image" and F9 (sequential pressing first the Alt key, then, while holding down, the F9 key). If the program is written correctly and without errors, the following message will appear: "Compile Successful: Press any key". Otherwise, the compilation will be interrupted, and the cursor in the program input window will move to the place with the error. Before running the program, you must make it compile successfully.

Step 4

Once compiled, the program can be run and tested using the Ctrl and F9 keyboard shortcuts. If there are no errors, then the program will start successfully, displaying the result of the execution. If not, then the location of the error will be indicated and its explanation will pop up in the form of a red table.

Recommended: