c++ learning 1 -- first test output

#include <iostream>
using namespace std;

intmain ()
{
    cout << " hello world << endl " ; // output text 

    system( " pause " ); // easy to observe the result 
    return  0 ;
}

// sign bit comment

/* */ Multi-line comments appear in pairs, if there are multiple lines of comments between /* */, it is easy to make mistakes

#if #endif Use the features of C++ code to comment with preprocessing

#include <iostream>
using namespace std;

intmain ()
{
    cout << " hello world << endl " ; // output text

#if 0 
    cout << " hello world << endl " ; // output text 
    cout << " hello world << endl " ; // output text 
    cout << " hello world << endl " ; // output text 
    cout < < " hello world << endl " ; // output text 
#endif

    system( " pause " ); // Easy to observe the result 
    return  0 ;
}    

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324940370&siteId=291194637