fork download
  1. #include <stdio.h>
  2.  
  3. int main() {
  4. #ifdef __cplusplus
  5. printf("C++ compiler\n");
  6. #else
  7. #ifdef __STDC__
  8. #if (defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L)) ||/*continue..
  9. ...on the next line */ (defined(__GNUC__) && !defined(__STRICT_ANSI__))
  10. printf("ANSI X3.159-1999 / ISO 9899:1999 (C99) compiler\n");
  11. #else
  12. printf("ANSI X3.159-1989 (C89) / ISO/IEC 9899:1990 (C90) C compiler\n");
  13. #endif
  14. #else
  15. printf("Pre-ANSI (K&R) C compiler\n");
  16. #endif
  17. #endif
  18. }
Success #stdin #stdout 0.01s 5316KB
stdin
Standard input is empty
stdout
ANSI X3.159-1999 / ISO 9899:1999 (C99) compiler