Thursday, April 11

TIME$

The TIME$ statement is used to set or retrieve the current time.
Sytnax
TIMES $ = string exp. (as a statement)
String exp. = TIMES (as a variable)
Where,
string exp.  :  Valid string variable that lets you to set hour, minute and second (hh : mm : ss)
                  :  hour (0-23)
                  :  minute (0 -59)
                  :  second (0-59)

  • the current time is assigned to the string variable if TIMES is the expression in a LET or PRINT statement.
  • if string exp. = TIMES, TIME$ returns 8 character string in the form hh : mm : ss
Example 22
if you want to set time to 11.00 AM
TIME $ ="11:00" (press enter key)
Ok

PRINT TIME $
11:00:20 (press enter key)
Ok   
            

No comments:

Post a Comment