結果
問題 |
No.892 タピオカ
|
ユーザー |
![]() |
提出日時 | 2019-10-13 19:21:34 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 1,000 ms |
コード長 | 1,240 bytes |
コンパイル時間 | 1,193 ms |
コンパイル使用メモリ | 99,544 KB |
実行使用メモリ | 6,824 KB |
最終ジャッジ日時 | 2024-12-16 08:38:47 |
合計ジャッジ時間 | 1,878 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 6 |
ソースコード
#include <iostream> #include <sstream> #include <fstream> #include <string> #include <vector> #include <deque> #include <queue> #include <stack> #include <set> #include <map> #include <algorithm> #include <functional> #include <utility> #include <bitset> #include <cmath> #include <cstdlib> #include <cstdio> using namespace std; const long long INF = 100000000; const long long MOD = 1000000007; std::vector<bool> IsPrime; void sieve(size_t max) { if (max + 1 > IsPrime.size()) { // resizeで要素数が減らないように IsPrime.resize(max + 1, true); // IsPrimeに必要な要素数を確保 } IsPrime[0] = false; // 0は素数ではない IsPrime[1] = false; // 1は素数ではない for (size_t i = 2; i * i <= max; ++i) // 0からsqrt(max)まで調べる if (IsPrime[i]) // iが素数ならば for (size_t j = 2; i * j <= max; ++j) // (max以下の)iの倍数は IsPrime[i * j] = false; // 素数ではない } class Pointer{ public: long long p; long long w; }; int main() { int a, b, c, d, e, f; cin >> a >> b >> c>>d>>e>>f; if((a+c+e)%2!=0) cout << ":-(" << endl; else cout << ":-)" << endl; }