C++/New, and confused
Im in the process of learning c++ from a book i have, Im using Dev-c++ 4.9.9. Win xp pro
1. Whats the deal with, #include <iostream.h> It dont work, it only worlks if i do #include <iostream>, and then put using namespace std;
2.I have seen this written several times clrscr();, i assume it clears the screen, but it doesnt work, i get the error 'clrscr' undeclared (first use this function)
3. And finally. This is really bothering me, i get some programs off the web, its helps me learn, but i see, always people use void, indtead of int for the main function, like this
the book says to use int main(), and also, sometimes in the braces to put ( int argc, char *argv) argc.
I dont get it, when i try to compile using the void methode, i get the error 'main' must return int.
I am very troubled, i got all these programs from reliable sources, maybe i am confusing something with the old c language, i dont kno;w, but the progs should work, and they just dont, i have to always change th code around,
I have also tried to compile with gcc g++, same thing.
Thanks, for all you help, i appreciate it a lot.
Actually <iostream.h> ans clrscr() works with the old c++ compilers. They were extensively used with C like programming.ususlly suppoted by Turbo C 3.0 etc
and the new complilers like Borland5.0 ( although it is qiute old version now ) doesnot support it.
name space std etc... They are the pure C++ statements supported by the new Compilers.
I hope this could help.