fork download
  1. #include<stdio.h>
  2.  
  3. #define abc() *(f())
  4.  
  5. int *f()
  6. {
  7. static int d;
  8. return &d;
  9. }
  10.  
  11. int main()
  12. {
  13. int i;
  14.  
  15. abc() = 123;
  16. i = abc();
  17. printf("%d\n", i);
  18.  
  19. abc() = 321;
  20. i = abc();
  21. printf("%d\n", i);
  22.  
  23. return 0;
  24. }
  25.  
Success #stdin #stdout 0s 1788KB
stdin
Standard input is empty
stdout
123
321