[ create a new paste ] login | about

Link: http://codepad.org/Vpr8BYhv    [ raw code | output | fork ]

pjvangemmeren - C++, pasted on May 29:
#include <iostream>
using namespace std;

char choice1;

int main ()
{
    cout << "This is a C++ program.\n";
    cout << "C++ is a programming language.\n";
    cout << "C++ was created by Sauce Labs in 2004 as a new version of the original program, C.\n";
    cout << "Would you like to learn more (y/n)?";
    cin >> choice1;
    if (choice1 == y)
    {
        cout << "Executing program...\n";
        break (5);
        cout << "Getting cloud data...\n";
        break (5)
        cout << "Restoring servers...\n";
        break (5)
        cout "Done. Please wait.\n";
        break (5)
        cout "C++ is an awesome programming language. If you like making stuff, learn it."
    }
return0;
}


Output:
1
2
3
In function 'int main()':
Line 13: error: 'y' was not declared in this scope
compilation terminated due to -Wfatal-errors.


Create a new paste based on this one


Comments: