Next: Introduction to Procedures
Up: Program Units
Previous: Main Program Syntax
PROGRAM Main
IMPLICIT NONE
REAL :: x
READ*, x
PRINT*, FLOOR(x) ! Intrinsic
PRINT*, Negative(x)
CONTAINS
REAL FUNCTION Negative(a)
REAL, INTENT(IN) :: a
Negative = -a
END FUNCTION Negative
END PROGRAM Main
For more information, click here
Next: Introduction to Procedures
Up: Program Units
Previous: Main Program Syntax
©University of Liverpool, 1997
Wed May 28 23:37:18 BST 1997Not for commercial use.