LET HOTDATE$ = DATE$(6)
Well, that was easy. To ask for the 6th item in the array, all you do is use subscript 6. What if the 6 is kept in a variable? Inspect the following program:
DIM DAY$(1 TO 7) ' Make an array of seven strings LET DAY$(1) = "Monday" ' Make "Monday" the first item LET DAY$(2) = "Tuesday" LET DAY$(3) = "Wednesday" LET DAY$(4) = "Thursday" LET DAY$(5) = "Friday" LET DAY$(6) = "Saturday" LET DAY$(7) = "Sunday" LET WHICH = 6 LET HOTDATE$ = DAY$(WHICH) PRINT "Important date on:", HOTDATE$ END
The program uses correct syntax.
The expression DAY$(WHICH)
is a correct subscripted variable.
What will the above program write out?