fork download
  1. #include <stdio.h>
  2. #include <string.h>
  3. #include <strings.h>
  4.  
  5.  
  6. int main(void) {
  7.  
  8.  
  9. char boop[11] = "bobobobobo";
  10. int len;
  11. len = strlen(boop);
  12.  
  13. char all[len + 1];
  14.  
  15. int i;
  16. for (i = 0; i < len; i++) {
  17. if (boop[i] != '\0') {
  18. strcat(all, boop[i]);
  19. }
  20.  
  21. }
  22. all[len + 1] = '\0';
  23.  
  24. printf("the new all string is: %s", all);
  25.  
  26. return 0;
  27. }
Runtime error #stdin #stdout 0s 2156KB
stdin
Standard input is empty
stdout
Standard output is empty