12.07.2015 Views

Intel® Fortran Libraries Reference

Intel® Fortran Libraries Reference

Intel® Fortran Libraries 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.

2 Intel <strong>Fortran</strong> <strong>Libraries</strong> <strong>Reference</strong>character*80 mainstringcharacter*4 shortstrinteger(4) wheremainstring="Hello Hello Hello Hello There There There"shortstr="Hello"where=rindex(mainstring,shortstr)! where is 19RTCPortability Function: Returns the number of seconds elapsed since a specific Greenwich meantime.Module: USE IFPORTSyntaxresult = RTC ( )Results:The result type is REAL(8). The result is the number of seconds elapsed since 00:00:00Greenwich mean time, January 1, 1970.CompatibilityCONSOLE STANDARD GRAPHICS QUICKWIN GRAPHICS WINDOWS DLL LIBSee Also: “TIMEF”, the DATE_AND_TIME intrinsic procedure in the Language <strong>Reference</strong>ExampleUSE IFPORTreal(8) s, s1, time_spentINTEGER(4) i, js = RTC( )call sleep(4)s1 = RTC( ) time_spent = s1 - sPRINT *, 'It took ',time_spent, 'seconds to run.'RUNQQPortability Function: Executes another program and waits for it to complete.Module: USE IFPORT2-380

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

Saved successfully!

Ooh no, something went wrong!