結果

問題 No.780 オフ会
ユーザー nisshimo
提出日時 2019-01-17 20:28:06
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 284 bytes
コンパイル時間 429 ms
コンパイル使用メモリ 55,476 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-07-01 10:11:23
合計ジャッジ時間 1,215 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other WA * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
using namespace std;

int main()
{
    int a, b, num;
    cin >> a >> b;
    if (a < b)
    {
        num = b - a - 1; 
        cout << "Yes" << endl << num << endl;
    }
    else
    {
        num = a + 1 - b;
        cout << "No" << endl << num << endl;
    }
}
0