I have two files main.cpp and T.cpp
T.cpp cosists following
#include <iostream.h>
class TEXT{
public:
void g(void){
cout<<"Hello World!";
}
};
and main.cpp
#include <iostream.h>
TEXT text; // I think that is mistake
int main(void){
text.g();
return 0;
}
Why dosn't this program work? I have used
extern TEXT text;
But this doasn`t work also.
What is the problem.