i cant use loops in the program
and i need to enter the string in a row
without telling what its length first.
this loop does exactly that
but i cant use for/while in the program
how to substitute it?Code:printf("enter string\n");
for (i = 0; i < 39 && (ch = getchar()) != '\n' && ch != EOF; ++i)
{
input2[i] = ch;
}
input2[i] = '\0';