Compiling and Running a FORTRAN program

To compile a text file program into a binary file which contains the information and memory allocations for the variables of the program. Type the following:

    f77 "program-name.f"

If there is problem a list of the errors will be produced imediately. Go back to the text file using pico and correct your mistakes.

If everything is fine. You'll wish to run the program. Type the following to run the file a.out generated from the f77 command:

    ./a.out

The program will then run. You will enter data as requested, and then see the output. Remember to select a range of input data to check your programming.

Return to Introduction to FORTRAN.