home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / listings / v_08_12 / 8n12023b < prev    next >
Text File  |  1990-10-09  |  258b  |  22 lines

  1.  
  2. #include <stdio.h>
  3.  
  4. main()
  5. {
  6.     int *f(void);
  7.  
  8.     f()[2] = 'x';
  9.     printf("%c %c %c %c\n", f()[0], 
  10.         f()[1],  f()[2],  f()[3]);
  11. }
  12.  
  13. int *f(void)
  14. {
  15.     static int a[] = {'a', 'b', 'c', 'd'};
  16.  
  17.     return &a[0];    /* or simply, return a; */
  18. }
  19.  
  20. a b x d
  21.  
  22.