From 23a286a86129a180dfbd8c4e765b65348bfe94bb Mon Sep 17 00:00:00 2001 From: Tyler Steppat Date: Mon, 8 Sep 2025 11:29:20 -0700 Subject: [PATCH] display full math operations, closes #62 --- main.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/main.cpp b/main.cpp index 958ba61..17c7f7f 100644 --- a/main.cpp +++ b/main.cpp @@ -12,13 +12,13 @@ int main() int x,y; cin >> x >> y; - cout << "Addition: " << x + y << endl; - cout << "Subtraction: " << x - y << endl; - cout << "Multiplication: " << x * y << endl; - cout << "Division: " << x / y << endl; - cout << "Remainder: " << x % y << endl; - cout << "Square Root: " << sqrt(x) << endl; - cout << "Square: " << pow(x, y) << endl; + cout << x << "+" << y << "=" << x + y << endl; + cout << x << "-" << y << "=" << x - y << endl; + cout << x << "*" << y << "=" << x * y << endl; + cout << x << "/" << y << "=" << x + y << " with a remainder of " << x % y << endl; + cout << "Square root of " << x << " is " << sqrt(x) << endl; + cout << "Square root of " << y << " is " << sqrt(y) << endl; + cout << x << "^" << y << "=" << pow(x, y) << endl; return 0; }