よじろめ覚書

私の理解度重視のソースコードです。

2019-10-15から1日間の記事一覧

ABC084B - Postal Code

ABC

問題:B - Postal Code #include <iostream> #include <string> using namespace std; #define FOR(i, a, b) for (int i = (a); i < (b); ++i) #define REP(i, n) for (int i = 0; i < (n); ++i) int main(void) { int a, b; string s; bool flg = true; cin.tie(0); ios::sync</string></iostream>…

ABC084A - New Year

ABC

問題:A - New Year #include <iostream> using namespace std; int main(void) { int m; cin.tie(0); ios::sync_with_stdio(false); cin >> m; cout << 2 * 24 - m << "\n"; return 0; }</iostream>

ABC083B - Some Sums

ABC

問題:B - Some Sums #include <iostream> using namespace std; #define REP(i, n) for (int i = 0; i < (n); ++i) int main(void) { int n, a, b, tmp, sum, ans = 0; cin.tie(0); ios::sync_with_stdio(false); cin >> n >> a >> b; REP(i, n + 1) { tmp = i; sum =</iostream>…