fork download
  1. #include <stdio.h>
  2.  
  3. void foon(int n) {
  4. printf("%d\n", n);
  5. }
  6.  
  7. int main(void) {
  8. (int){42};
  9.  
  10. //you can use it through a pointer
  11. int *foo = &((int){42});
  12. *foo = -1;
  13.  
  14. // you can use it as a function parameter
  15. foon((int){42});
  16.  
  17. return 0;
  18. }
  19.  
Success #stdin #stdout 0s 4368KB
stdin
Standard input is empty
stdout
42