結果

問題 No.441 和か積
コンテスト
ユーザー ferin
提出日時 2017-01-25 16:50:54
言語 C++14
(gcc 15.2.0 + boost 1.89.0)
コンパイル:
g++-15 -O2 -lm -std=c++14 -Wuninitialized -DONLINE_JUDGE -o a.out _filename_
実行:
./a.out
結果
AC  
実行時間 2 ms / 1,000 ms
コード長 702 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 1,158 ms
コンパイル使用メモリ 179,796 KB
実行使用メモリ 6,144 KB
最終ジャッジ日時 2026-03-14 08:23:16
合計ジャッジ時間 2,158 ms
ジャッジサーバーID
(参考情報)
judge3_0 / judge1_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 30
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

#include <bits/stdc++.h>

using namespace std;
typedef long long ll;
typedef vector<int> VI;
typedef vector<VI> VVI;
typedef vector<ll> VL;
typedef vector<VL> VVL;
typedef pair<int, int> PII;

#define FOR(i, a, n) for (int i = (int)a; i < (int)n; ++i)
#define REP(i, n) FOR(i, 0, n)
#define ALL(x) x.begin(), x.end()
#define MOD 1000000007
#define INF 1000000000
#define PI 3.14159265359
#define EPS 1e-12

int main(void)
{
  string a, b;
  cin >> a >> b;
  if(a == "0" && b == "0" || a == "2" && b == "2") {
    cout << "E" << endl;
    return 0;
  } else if(a == "0" || a == "1" || b == "0" || b == "1") {
    cout << "S" << endl;
    return 0;
  } else {
    cout << "P" << endl;
  }

  return 0;
}
0