#include <stdio.h> 
#include <time.h>
/* Define global time variables */
int year, month, day, hour, minute;
void assign_time_variables ( ) {
  /* Declare variable to hold elapsed seconds since 1970 */
  time_t elapsed_seconds;
  /* Declare pointer to an object containing time information */
  struct tm *time_structure_pointer;
  /* Fetch elapsed seconds from operating system */
  time(&elapsed_seconds);
  /* Use elapsed seconds to update time-structure object */
  time_structure_pointer = localtime (&elapsed_seconds);
  /* Extract useful information from the time structure */
  year = 1900 + time_structure_pointer -> tm_year;
  month = time_structure_pointer -> tm_mon;
  day = time_structure_pointer -> tm_mday;
  hour = time_structure_pointer -> tm_hour;
  minute = time_structure_pointer -> tm_min;
}
main ( ) {
  assign_time_variables ( );
  printf ("At %i:%s%i, ...\n",
              hour,
                 (minute < 10) ? "0" : "",
                   minute);
}
