Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using std::cin;
- using std::cout;
- int main()
- {
- int a{2};
- int b{3};
- cout << a << " * " << b << " = ? ";
- int userAnswer{};
- cin >> userAnswer;
- if (userAnswer == (a*b) )
- {
- cout << "Correct!\n";
- }
- else
- {
- cout << "Wrong!\n";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement