Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 30 |
31 |
Tags
- c++
- 백준
- Unreal Engine 5
- W3Schools
- Tutorial
- guide
- Class
- 문제풀이
- DP
- w3school
- 재귀
- C#
- String
- UE5
- python
- Programming
- Algorithm
- 프로그래밍
- Unity
- dynamic
- Basic
- github
- 기초
- parameter
- loop
- 오류
- 파이썬
- Material
- 시작해요 언리얼 2022
- dfs
Archives
- Today
- Total
행복한 개구리
(Python/C#/C++) 백준 10869번 - 사칙연산 본문


Python
A, B = map(int, input().split())
arr = [A+B, A-B, A*B, int(A/B), A%B]
for i in range(5):
print(arr[i])
C#
string[] input = Console.ReadLine().Split();
int A = int.Parse(input[0]);
int B = int.Parse(input[1]);
int[] result = { A+B, A-B, A*B, A/B, A%B};
for (int i = 0; i < 5; i++)
{
Console.WriteLine(result[i]);
}
C++
#include <iostream>
using namespace std;
int main() {
int a, b;
cin >> a >> b;
int result[5] = { a + b, a - b, a * b, a / b, a % b };
for (int i = 0; i < 5; i++) {
cout << result[i] << endl;
}
}
'Algorithm > BaekJoon' 카테고리의 다른 글
(Python/C#/C++) 백준 18108번 - 1998년생인 내가 태국에서는 2541년생?! (0) | 2022.07.11 |
---|---|
(Python/C#/C++) 백준 10926번 - ??! (0) | 2022.07.11 |
(C++/C#/Python) 백준 1008번 - A/B (0) | 2022.07.08 |
(C++/Python/C#) 백준 10998번 - A*B (0) | 2022.07.08 |
(C++/Python) 백준 1001번 - A-B (0) | 2022.07.08 |