C. Simple Calculator – Codeforces Problem Solution in C++

Disclaimer: Make sure you tried enough before checking the solution

Problem: https://codeforces.com/group/MWSDmqGsZm/contest/219158/problem/C

#include<bits/stdc++.h>
using namespace std;
int main()
{
	long long num1,num2;
	cin>>num1>>num2;
	cout<<num1<<" + "<<num2<<" = "<<num1+num2<<endl;
	cout<<num1<<" * "<<num2<<" = "<<num1*num2<<endl;
	cout<<num1<<" - "<<num2<<" = "<<num1-num2<<endl;
}

Assiut University Training – Newcomers solution

Leave a Comment