home *** CD-ROM | disk | FTP | other *** search
- #include <scl1.h>
-
- /*******************************
- shows the GetDate function */
-
- char *Day[]={"Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"};
-
- char *Month[]={"","January","February","March","April","May","June",
- "July","August","September","October","November","December"};
-
- main()
- {
- struct DateData *p;
- p=GetDate();
-
- /* p points to DateData structure:
- p->WeekDay = day of the week (0=Sunday),
- p->MonthDay = day (1-31),
- p->Month = month (1-12)
- p->Year = year (1980 - 2099).
- The month and day numbers reported by GetDate will be used as an
- index to the week and months names arrays we have previously
- defined.*/
-
- printf("\n\nToday is %s, %s %d,%d",Day[p->WeekDay],Month[p->Month],p->MonthDay,p->Year);
- }
-