this is my code.

the input numbers are

1234567890

the output of this code should be

(123)456-7890

but the output is different. Any advice or error fixes in my code?

```
#include <stdio.h>
#include <ctype.h>

int main()
{
    char ch;
    int a[100], s[100], str, k, i;
    FILE *fp;

    fp = fopen("number.c", "r");
    while ( ( ch = fgetc(fp) ) != EOF )
    {
        k = 0;
        a[k] = '(';
        a[k+4] = ')';
        a[k+8] = '-';
        for (i = 0; s[i] != '\0'; i++)
        {
            if (isdigit(s[i]))
            {
                a[k++] = s[i];
                if (k == 3)
                {
                    k++;
                }
            }
            printf("%s", a);
        }
        fclose(fp);
        return 0;
    }
}

```