-
백준 15552번 빠른 A+B백준 algorithm 2020. 7. 8. 21:28반응형
https://www.acmicpc.net/problem/15552
15552번: 빠른 A+B
첫 줄에 테스트케이스의 개수 T가 주어진다. T는 최대 1,000,000이다. 다음 T줄에는 각각 두 정수 A와 B가 주어진다. A와 B는 1 이상, 1,000 이하이다.
www.acmicpc.net
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters#include <iostream> #include <vector> using namespace std; int main(void) { int test_case = 0; cin >> test_case; vector<int> x(test_case); vector<int> y(test_case); for (int i = 0; i < test_case; i++) { cin >> x[i] >> y[i]; } for (int i = 0; i < test_case; i++) { cout << x[i] + y[i] << "\n"; } return 0; } 728x90'백준 algorithm' 카테고리의 다른 글
백준 10039번 (0) 2020.07.15 백준 10951번 A+B_4 (0) 2020.07.09 백준 2741 번 N 찍기 (0) 2020.07.08 백준 2742번 기찍 N (0) 2020.07.08 백준 11021번 A+B-7 (0) 2020.07.08