結果

問題 No.892 タピオカ
ユーザー lice6613lice6613
提出日時 2019-12-09 19:43:38
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
TLE  
実行時間 -
コード長 413 bytes
コンパイル時間 420 ms
コンパイル使用メモリ 64,744 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-06-23 04:07:11
合計ジャッジ時間 3,169 ms
ジャッジサーバーID
(参考情報)
judge4 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 2 TLE * 1 -- * 3
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
using namespace std;

int main() {
  int A1, B1, A2, B2, A3, B3;
  cin >> A1 >> B1 >> A2 >> B2 >> A3 >> B3;
  int t1 = A1, t2 = A2, t3 = A3;
  for (int i = 0; i < B1; ++i)
    t1 = t1 * A1 % 2;
  for (int i = 0; i < B2; ++i)
    t2 = t2 * A2 % 2;
  for (int i = 0; i < B3; ++i)
    t3 = t3 * A3 % 2;
  if ((t1 + t2 + t3) % 2 == 0)
    cout << ":-)" << endl;
  else
    cout << ":-(" << endl;
}
0