Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Question about READ

Status
Not open for further replies.

ctpiper

Programmer
Joined
Feb 17, 2012
Messages
1
Location
US
Hi-

I'm new to using fortran, and I'm having trouble undertstanding the READ command. I'm supposed to make my own version of a code for practice.

THis deals with reading files.

The file was opened like this:

open(unit=1, file=arg1, status='old')

And the read command, a couple lines later says this:

read(1,1,end=15)s

I know that the first 1 means unit 1, and the end=15 refers to a label. What does the second 1 mean? Is it a line number or a character number?
 
This would stand for a label of a format statement. If your compiler does not give an errormessage, somewhere in this program unit there is a statement

1 format (...)

which provides directions on how s is to be read.

Norbert


The optimist believes we live in the best of all possible worlds - the pessimist fears this might be true.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top