fork download
  1. #include <stdio.h>
  2. #include <string.h>
  3.  
  4. int main(void) {
  5. char nomeString[] = "nomedoarquivo.txt";
  6. nomeString[strlen(nomeString) - 4] = '\0';
  7. printf("%s", nomeString);
  8. }
  9.  
  10. //https://pt.stackoverflow.com/q/168134/101
Success #stdin #stdout 0s 4224KB
stdin
Standard input is empty
stdout
nomedoarquivo