I am a total n00b at C++

This is a discussion on I am a total n00b at C++ within the C++ Programming forums, part of the General Programming Boards category; wow there are more and more of these poping up every week... i wish there was some kinda warning message ...

  1. #16
    Registered User Liam Battle's Avatar
    Join Date
    Jan 2002
    Posts
    114
    wow there are more and more of these poping up every week...
    i wish there was some kinda warning message when people register
    LB0: * Life once school is done
    LB1: N <- WakeUp;
    LB2: N <- C++_Code;
    LB3: N >= Tired : N <- Sleep;
    LB4: JMP*-3;

  2. #17
    Seeking motivation... endo's Avatar
    Join Date
    May 2002
    Posts
    537
    Originally posted by skipper
    Tur13o,

    Header files contain a collection of "library" files (functions).

    For example, sqrt() is a library (.lib) function contained in the header file <cmath>.

    When the compiler sees a preprocessor directive such as #include <cmath>, those files (functions) are added to your code.

    (Yes, all of them!)

    When you elect to access a particular pre-defined function, the compiler looks to see if the appropriate header file has been "included". If it has, you're "golden". If not, you score a compiler error.

    That is, you've attempted to access a function that's not part of your code.

    Not an elegant explanation, but I hope it helps.



    Not so sure about the accuracy of all of those statements...

  3. #18
    Registered User
    Join Date
    Apr 2002
    Posts
    362
    Endo,

    I'm open to polite, constructive criticism. Where am I in error regarding header files?

    "When the only tool you own is a hammer, every problem begins to resemble a nail." Abraham Maslow

  4. #19
    Pygmy Monkey ErionD's Avatar
    Join Date
    Feb 2002
    Posts
    408
    I dont see anything wrong except for you calling the functions library files.
    They are defined in the library files but they ARE not library files;

  5. #20
    Registered User
    Join Date
    Apr 2002
    Posts
    362
    ErionD,

    Thanks for the input.

    I didn't think I was way off-base in my response but I do appreciate you pointing out my "goof".

    "When the only tool you own is a hammer, every problem begins to resemble a nail." Abraham Maslow

Page 2 of 2 FirstFirst 12
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Help with day of the week program
    By Punkakitty in forum C++ Programming
    Replies: 10
    Last Post: 01-14-2009, 05:55 PM
  2. Replies: 8
    Last Post: 11-03-2008, 08:48 PM
  3. long problem
    By loko in forum C Programming
    Replies: 28
    Last Post: 07-22-2005, 09:38 AM
  4. Loops
    By Dt7 in forum C++ Programming
    Replies: 3
    Last Post: 10-23-2004, 06:11 PM
  5. Replies: 4
    Last Post: 04-22-2003, 12:52 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21