-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
29 lines (22 loc) · 801 Bytes
/
main.cpp
File metadata and controls
29 lines (22 loc) · 801 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include <iostream>
#include <string>
using namespace std;
string bigSum(string firstNum, string secondNum); // 덧셈 연산 함수
string bigSub(string firstNum, string secondNum); // 뺄셈 연산 함수
int main(){
//첫번째 수와 두번쨰 수의 값을 저장할 변수
string firstNum;
string secondNum;
//첫번째 수와 두번째 수를 입력 받음
cout << "First number >> ";
cin >> firstNum;
cout << "Second number >> ";
cin >> secondNum;
//덧셈 결과 출력
string sumResult = bigSum(firstNum, secondNum);
cout << "Sum >> "<< sumResult<<endl;
//뺄셈 결과 출력
string subResult = bigSub(firstNum, secondNum);
cout << "Sub >> "<< subResult<<endl;
return 0;
}