i have two file.
file1.cpp
file2.cppCode:#include<stdio.h> void func(int A[]); int main() { int A[20]; A[0]=123; A[1]=456; func(A); printf(" %d",A[2]); return 0; }
//here is the body of the function
then i did " add files to the project " and " rebuild all " to compile and run in VC++ ...... but i am getting " file2.cpp printf' : undeclared identifier " error.Code:void func(int A[]) { A[2] = A[0] + A[1]; printf(" hello "); //here i am getting error !!!!!! }
but i need to print some variable etc inside that function . how can i print something(e.g value of variable etc) inside that function ???
thanks...
blue_gene