i have another function problem
any help would be good
Code:
#include<stdio.h>
#include<ctype.h>
int i,d;
void rever(char string1[],char string2[])
{
extern int d,i;
string2[i++]=string1[d--];
if(d>=0)
/*12.line*/ rever( string1[],string2[]);
}
main(){
extern int d,i;
int a,b,c;
extern char string1[1000],string2[1000];
a=0;
while((b=getchar()) !=EOF)
string1[a++]=b;
string2[a]=0;
d=a-1;
i=0;
/*34. line*/ rever(string1[],string2[]);
string2[i]=0;
printf("%s",string2);
getchar();
return 0;
}
i get this error as usual
syntax error before ']' token
line 12 and 34(both lines when i call rever() function)
i always get this but why?
again any help at all will be appriciated