結果
問題 |
No.780 オフ会
|
ユーザー |
![]() |
提出日時 | 2019-01-11 21:31:06 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 1,018 bytes |
コンパイル時間 | 550 ms |
コンパイル使用メモリ | 70,964 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-30 04:24:21 |
合計ジャッジ時間 | 1,230 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 23 |
ソースコード
#include<iostream> #include<vector> #include<algorithm> #include<utility> #include<string> #include<cmath> #include<cstring> #include<queue> #include<map> #include<climits> #include<queue> #define REP(i, n) for(int i = 0;i < n;i++) #define REPR(i, n) for(int i = n;i >= 0;i--) #define FOR(i, m, n) for(int i = m;i < n;i++) #define FORR(i, m, n) for(int i = m;i >= n;i--) #define SORT(v, n) sort(v, v+n); #define VSORT(v) sort(v.begin(), v.end()); #define llong long long #define pb(a) push_back(a) using namespace std; typedef pair<int, int> P; typedef long long int ll; typedef pair<ll,ll> LLP; int dx[4] = {1,0,0,-1}; int dy[4] = {0,1,-1,0}; #define INF 1000000000007 #define MOD 1000000007 #define ARRAY_MAX 3005 double dp[ARRAY_MAX][ARRAY_MAX];//dp[i][j]:i回投げて表がj回出る確率 int main(){ int a,b; cin >> a >> b; if(a+1 <= b){ cout << "YES" << endl; cout << b-a-1 << endl; }else{ cout << "NO" << endl; cout << a-b+1 << endl; } return 0; }