help me to compile these code please
errors in visual c++Code:#include "stdio.h" #include "string.h" #define n 100 void e(int i,int *t[i],int *a[i]) { *t[i]=1; *a[i]=1; } void main() { int k=1; int a[n],b[n]; e(k,&a[k],&b[k]); printf("a[k]=%i et b[k]=%i",a[k],b[k]); }
--------------------Configuration: hello - Win32 Debug--------------------
Compiling...
oiu.cpp
C(4) : error C2057: expected constant expression
C:\Program Files\Microsoft Visual Studio\MyProjects\hello\oiu.cpp(4) : error C2466: cannot allocate an array of constant size 0
C:\Program Files\Microsoft Visual Studio\MyProjects\hello\oiu.cpp(4) : error C2057: expected constant expression
C:\Program Files\Microsoft Visual Studio\MyProjects\hello\oiu.cpp(4) : error C2466: cannot allocate an array of constant size 0
C:\Program Files\Microsoft Visual Studio\MyProjects\hello\oiu.cpp(6) : error C2143: syntax error : missing ';' before '->'
C:\Program Files\Microsoft Visual Studio\MyProjects\hello\oiu.cpp(7) : error C2143: syntax error : missing ';' before '->'
C:\Program Files\Microsoft Visual Studio\MyProjects\hello\oiu.cpp(14) : error C2664: 'e' : cannot convert parameter 2 from 'int *' to 'int *[]'
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
Error executing cl.exe.
hello.exe - 7 error(s), 0 warning(s)