2 ! Program to test reading in a list of integer values into REAL variables.
3 ! The comma separator was not handled correctly.
15 write (buff
,'(a)') '10,20,30,40'
16 read(buff
,*) a
, b
, c
, d
23 if (abs(10. - a
) > 1e-5) call abort
24 if (abs(20. - b
) > 1e-5) call abort
25 if (abs(30. - c
) > 1e-5) call abort
26 if (abs(40. - d
) > 1e-5) call abort
32 write (buff
,'(a)') '10.,20.,30.,40.'
33 read(buff
,*) a
, b
, c
, d
35 if (abs(10. - a
) > 1e-5) call abort
36 if (abs(20. - b
) > 1e-5) call abort
37 if (abs(30. - c
) > 1e-5) call abort
38 if (abs(40. - d
) > 1e-5) call abort
49 write (buff
,'(a)') '10.0,20.0,30.0,40.0'
50 read(buff
,*) a
, b
, c
, d
52 if (abs(10. - a
) > 1e-5) call abort
53 if (abs(20. - b
) > 1e-5) call abort
54 if (abs(30. - c
) > 1e-5) call abort
55 if (abs(40. - d
) > 1e-5) call abort
67 write (buff
,'(a)') '10.0,,30.0,40.0'
68 read(buff
,*) a
, b
, c
, d
70 if (abs(10. - a
) > 1e-5) call abort
71 if (abs(-99. - b
) > 1e-5) call abort
72 if (abs(30. - c
) > 1e-5) call abort
73 if (abs(40. - d
) > 1e-5) call abort
87 character(len
=80) buff
93 write (buff
,'(a)') '10,-20,30,-40'
94 read(buff
,*) a
, b
, c
, d
96 if (abs(10. - a
) > 1e-5) call abort
97 if (abs(-20. - b
) > 1e-5) call abort
98 if (abs(30. - c
) > 1e-5) call abort
99 if (abs(-40. - d
) > 1e-5) call abort