fork download
  1. /* user defined structure type for a date */
  2. struct date
  3. {
  4. int month;
  5. int day;
  6. int year;
  7. };
  8.  
  9. #include <stdio.h>
  10. int main ()
  11. {
  12.  
  13. struct date today; /* defines a variable of type struct date */
  14.  
  15. today.month = 7;
  16. today.day = 23;
  17. today.year = 1985;
  18.  
  19. printf ("%i/%6.2f/%f \n", today.month, today.day, today.year); /* Y2K Issue ? */
  20.  
  21. return (0);
  22.  
  23. }
Success #stdin #stdout 0s 5320KB
stdin
Standard input is empty
stdout
7/  0.00/0.000000