Thread: C++ Help

  1. #1
    Registered User
    Join Date
    Mar 2002
    Posts
    3

    C++ Help

    Hi!

    I'm trying to learn C++. I've just started reading tutorials on cprogramming.com

    I'm having a few problems, can someone give me a little Hello World! script, or any other kind of script so I can stick it in my compiler and test it, just so I can see a working script so I know the basis of them?

    I'd appreciate it, thanks!

    Jordan

  2. #2
    Fingerstyle Guitarist taylorguitarman's Avatar
    Join Date
    Aug 2001
    Posts
    564
    You no longer write scripts. You write programs.

    Code:
    #include <iostream>
    
    using namespace std;
    
    int main( int argc, char *argv[] ) {
    
      cout << "Hello World!" << endl;
    
      return 0;
    }
    If a tree falls in the forest, and no one is around to see it, do the other trees make fun of it?

  3. #3
    Registered User
    Join Date
    Jan 2002
    Location
    Vancouver
    Posts
    2,212
    phh, that hello world program is inferior.

    Code:
    #include <stdio.h>
    int main(void) { return printf("Hello, world!\n"); }

Popular pages Recent additions subscribe to a feed