Skip to main content

7.2) Multiple Lines


If the data in ‘input.dat’ is stored on different rows (lines):

3.4
5.7
6.8

Then a program with the following can read these values:

open(22,file=’input.dat’)
read(22,*) a
read(22,*) b
read(22,*) c