Intel® Fortran Compiler Classic and Intel® Fortran Compiler Developer Guide and Reference

ID 767251
Date 11/07/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

IDATE Intrinsic Procedure

Intrinsic Subroutine (Generic): Returns three integer values representing the current month, day, and year. IDATE can be used as an intrinsic subroutine or as a portability routine. It is an intrinsic procedure unless you specify USE IFPORT. Intrinsic subroutines cannot be passed as actual arguments.

CALL IDATE (i, j, k)

i

(Output) Must be of type integer. It is the current month.

j

(Output) Must be of type integer with the same kind type parameter as i. It is the current day.

k

(Output) Must be of type integer with the same kind type parameter as i. It is the current year.

The current month is returned in i; the current day in j. The last two digits of the current year are returned in k.

CAUTION:

The two-digit year return value may cause problems with the year 2000. Use DATE_AND_TIME instead.

Example

If the current date is September 16, 1999, the values of the integer variables upon return are: I = 9, J = 16, and K = 99.