Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- cout << "Hello Youtube!\n";
- //The cout << tells the compiler that we will now be outputting in
- //the console. The contents between the semicolons will be what is
- //outputted. The \n tells the compiler to leave the rest of the line blank.
- //Again the trailing semicolon!
- cin.get();
- //Now we are telling the compiler to "pause" until it receives a key
- //stroke from the user.
- }
- //This is the standard new source file layout. Ill explain what each means
- // The #include <iostream> means that we are including the input and output
- // streams. The using namespace std; means that we are giving the program
- // permission to use the namespace which is std. Stops us from entering
- // std:: before all our commands. The trailing semicolon ';' is extremely
- // important. It shows the compiler that line of code is complete.
- // Ah how i love sticky fingers...
- // The next part, int main() is the declaration for our main function..
- // We will get into more detail when we do functions in a later stage.
- //Now lets compile and see what happens.
- //Thanks for watching. Hope that you learned something. If you did, please, like and subscribe. Check the description for the code.
- //Thanks, RhinoZA/
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement