이유를 모르겠습니다..
#include <stdio.h>
#include <string.h>
int main()
{
char str[1000];
char* rstr;
int len;
int i,j;
int count = 0;
// c = getchar();
while (fgets(str,1000,stdin)) {
len = strlen(str);
for (i = 0; i < len; i++) {
if (str[i] == "\t") {
j = i - 1;
count = 0;
for (int num = 0; num < 4; num++) {
if (str[j] == " ") count++; j--;
}
if (count == 0) {
str[i] = " ";
}
else if (count == 1) {
str[i] = " ";
}
else if (count == 2) {
str[i] = " ";
}
else if (count == 3) {
str[i] = " ";
}
}
}
printf("%s", str);
}
return 0;
}