Posts: 552
Threads: 23
Joined: Jul 2011
Reputation:
0
In my school our teacher uses TurboC 7 for us to write programs in. I personally have Code::Blocks.
Now, TurboC 7 would give an error for "use namespace std;". So what's up with that?
P.S. - I searched on ****** but I couldn't find any relevant information for TurboC 7.
P.S. 2 - I know this is not a C++ forum, but I don't want to register everywhere now, and this forums has some scripters/programmers so yeah.
Posts: 937
Threads: 69
Joined: Dec 2009
Reputation:
0
Well in C++ every program must have namespace std; included. You don't want to not include it, do you?
I found some information about turboc program in ******.
Posts: 772
Threads: 52
Joined: Aug 2010
Reputation:
0
If you want a decent IDE you should use Visual Studio or Netbeans. Personally I hate Code::Blocks (mainly because of the way it does auto formatting).
Posts: 2,286
Threads: 18
Joined: Jun 2010
Quote:
The use of namespace std for all identifiers of the C++ standard library was introduced during the standardization process. This change is not backward compatible to old header files, in which identifiers of the C++ standard library are declared in the global scope. In addition, some interfaces of classes changed during the standardization process (however, the goal was to stay backward compatible if possible). So, a new style for the names of standard header files was introduced. This allows vendors to stay backward compatible by providing the old header files.
The definition of new names for the standard header files was a good opportunity to standardize the extensions of header files. Previously, several extensions for header files were used; for example, .h, .hpp, and .hxx. However, the new standard extension for header files might be a surprise: Standard headers no longer have extensions. Hence, include statements for standard header files look like this:
|
Source:
http://my.safaribooksonline.com/0201...portal=oreilly