Thread: ANSI/ISO includes

  1. #1
    Grammar Police HybridM's Avatar
    Join Date
    Jan 2003
    Posts
    355

    ANSI/ISO includes

    Hey guys, i'm a total newbie, so forgive me if i'm wrong, but...

    I thought the standard for C++ now was <iostream>, <ctime> etc. without the .h, and that using .h was considered obsolete now. (i have complete reference Third Ed.)

    Howcome pretty much everyone uses .h, and even the c++ tutorials on this site?

    Thanks in advance..sorry for rampant n00bism.

  2. #2
    S Sang-drax's Avatar
    Join Date
    May 2002
    Location
    Göteborg, Sweden
    Posts
    2,072
    Because it's very hard to relearn things for some people.

    There are lots of other stupid arguments too, like:
    "I like <iostream.h> because it allows me to omit 'using namespace std;'"

    This is true for many other aspects as well: void main, returning zero from main() etc.
    You should always use the correct headers.
    Last edited by Sang-drax : Tomorrow at 02:21 AM. Reason: Time travelling

  3. #3
    Grammar Police HybridM's Avatar
    Join Date
    Jan 2003
    Posts
    355
    Cool, i thought so, but i think the tutorials should be updated, people like me who are just learning can be easily misled.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Makefile and includes
    By Lang in forum C Programming
    Replies: 4
    Last Post: 03-18-2008, 03:29 AM
  2. Avoiding multiple includes
    By plan7 in forum C Programming
    Replies: 5
    Last Post: 11-25-2007, 06:13 AM
  3. added start menu crashes game
    By avgprogamerjoe in forum Game Programming
    Replies: 6
    Last Post: 08-29-2007, 01:30 PM
  4. Circular includes
    By ventolin in forum C++ Programming
    Replies: 2
    Last Post: 05-23-2004, 05:43 PM
  5. #includes
    By RedLenses in forum C++ Programming
    Replies: 3
    Last Post: 01-02-2002, 03:59 PM