24.11.2014 Views

Open Watcom FORTRAN 77 Language Reference

Open Watcom FORTRAN 77 Language Reference

Open Watcom FORTRAN 77 Language Reference

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>FORTRAN</strong> Statements<br />

2.70 REAL Statement<br />

The REAL statement is a type declaration statement and can be used to declare a name to be of type real.<br />

The implicit type of the name, whether defined by the "first letter rule" (see the chapter entitled "Names,<br />

Data Types and Constants" on page 151) or by an IMPLICIT statement, is either confirmed or overridden.<br />

However, once a name has been declared to be of type real, it cannot appear in another type declaration<br />

statement.<br />

There are various forms of the REAL statement. The following sections describe them.<br />

2.70.1 Standard REAL Statement<br />

<br />

REAL name [,name] ...<br />

where:<br />

name<br />

is a variable name, array name, array declarator, symbolic name of a constant, function name or<br />

dummy procedure name.<br />

This form is the standard form of the REAL statement.<br />

Example:<br />

DIMENSION C(-5:5)<br />

REAL A, B(10), C<br />

In the previous example, A is defined to be a variable of type real and B and C are defined to be arrays of<br />

type real.<br />

2.70.2 Extended REAL Statement: Length Specification<br />

REAL[*len[,]] name [,name] ...<br />

where:<br />

name<br />

is one of the following forms:<br />

v[*len]<br />

a[*len](d)<br />

a(d)[*len]<br />

v<br />

is a variable name, array name, symbolic name of a constant, function name or dummy<br />

procedure name.<br />

REAL Statement 127

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!