From 9b8b7c8a3d175fe5a3d8e3277e7f6228205df16b Mon Sep 17 00:00:00 2001 From: Mathias Wagner Date: Wed, 18 Oct 2023 10:25:45 +0200 Subject: [PATCH] Created the 2023_18_10 solution.cpp --- units/2023_18_10/solution.cpp | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 units/2023_18_10/solution.cpp diff --git a/units/2023_18_10/solution.cpp b/units/2023_18_10/solution.cpp new file mode 100644 index 0000000..8efdb63 --- /dev/null +++ b/units/2023_18_10/solution.cpp @@ -0,0 +1,26 @@ +#include + +using namespace std; + +int main() { + int x, y, z; + + cout << "Bitte einen Wert eingeben: "; + cin >> x; + + cout << "Bitte noch einen Wert eingeben: "; + cin >> y; + + cout << "Bitte noch einen Wert eingeben: "; + cin >> z; + + cout << "Die Summe der drei Zahlen betrÃĪgt " << x + y + z << "!" << endl; + + int a; + cout << "Bitte einen Wert eingeben: "; + + cin >> a; + + cout << "Das Produkt der Summe und der eingegebenen Zahl betraegt " << (x + y + z) * a << "!" << endl; + +} \ No newline at end of file