+ Reply to Thread
Results 1 to 10 of 12

Threaded View

  1. #1
    Join Date
    Oct 2009
    Posts
    120
    Points
    835,205.69
    Rep Power
    193

    Default Re: SonniE's C++ Tutorial

    Lol

    /*
    SonniE's Hello World C++ Example 1
    This Program Shows basic console printing skills
    */
    #include <iostream>

    using namespace std;

    int main()
    {
    cout<<"Hello World";
    system("pause");
    }
    You should have used this: (Less sloppy)

    /*
    SonniE's Hello World C++ Example 1
    This Program Shows basic console printing skills
    */
    #include <iostream>

    using namespace std;

    int main()
    {
    cout<<"Hello World\n";
    system("pause");
    }
    Other wise it's like this:

    Last edited by TheEliteOne; 03-19-2010 at 12:32 AM.

  2. #2
    Join Date
    Jan 2008
    Location
    PA
    Posts
    1,164
    Points
    4,213,718.25
    Rep Power
    222

    Default Re: SonniE's C++ Tutorial

    Quote Originally Posted by TheEliteOne View Post
    Lol



    You should have used this: (Less sloppy)



    Other wise it's like this:

    it doesn't need the linebreak the purpose of the code was to show the function that prints text. But if there was more to the program i would add a linebreak. You could use \n or the endl keyword.


    Get Vip: »Here«
    Donate: »Here«
    >>List of Compilers<<
    >>SFDM Name Generator<<
    [Owner Of FluidCoding]

+ Reply to Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts