結果
| 問題 |
No.892 タピオカ
|
| コンテスト | |
| ユーザー |
f843nmfwisfeuw
|
| 提出日時 | 2020-07-26 11:38:19 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 678 bytes |
| コンパイル時間 | 785 ms |
| コンパイル使用メモリ | 94,332 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-06-28 10:42:28 |
| 合計ジャッジ時間 | 1,271 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 6 |
ソースコード
#include <iostream>
#include <vector>
#include <algorithm>
#include <cmath>
#include <iomanip>
#include <stack>
#include <algorithm>
#include <string>
#include <map>
#include <iterator>
#include <set>
#include <queue>
using namespace std;
bool isEven(int n) {
return n % 2 == 0;
}
int main() {
long A1, B1, A2, B2, A3, B3;
cin >> A1 >> B1 >> A2 >> B2 >> A3 >> B3;
int numOfEven = 0;
vector<long> vs = {A1, A2, A3};
for (long v : vs) {
if (isEven(v)) {
numOfEven += 1;
}
}
if (numOfEven == 1 or numOfEven == 3) {
cout << ":-)" << endl;
} else {
cout << ":-(" << endl;
}
return 0;
}
f843nmfwisfeuw