結果

問題 No.441 和か積
ユーザー vjudge1
提出日時 2025-02-05 20:08:27
言語 C++23
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 3 ms / 1,000 ms
コード長 642 bytes
コンパイル時間 5,783 ms
コンパイル使用メモリ 275,928 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2025-02-05 20:08:35
合計ジャッジ時間 5,626 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 30
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
#define ll long long
#define pii pair<int, int>
#define pll pair<ll, ll>
#define tii tuple<int, int, int>
#define tll tuple<ll, ll, ll>
using namespace std;
constexpr int N = 2e5 + 5;

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

int main()
{
    ios::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);
    
    int t = 1;
    // cin >> t;
    while (t--) {
        solve();
        cout << '\n';
    }
    return 0;
}
0