fork download
  1. #include <stdio.h>
  2. #include <string.h>
  3.  
  4. int main(int argc, char *argv[])
  5. {
  6. char a[] = "J@RODQ";
  7.  
  8. if (argc != 2) {
  9. puts("WRONG!");
  10. return -1;
  11. }
  12.  
  13. if (strlen(argv[1]) != (sizeof(a) - 1)) {
  14. puts("WRONG!");
  15. return -1;
  16. }
  17.  
  18. for (int i = 0; i < sizeof(a)-1; i++) {
  19. if (argv[1][i] - !!a != a[i]) {
  20. puts("WRONG!");
  21. return -1;
  22. }
  23. }
  24.  
  25. puts("CORRECT!");
  26.  
  27. return 0;
  28. }
Runtime error #stdin #stdout 0s 9432KB
stdin
Standard input is empty
stdout
WRONG!