結果

問題 No.1205 Eye Drops
ユーザー auauaauaua
提出日時 2020-08-30 14:21:51
言語 C++14
(gcc 13.2.0 + boost 1.83.0)
結果
AC  
実行時間 66 ms / 2,000 ms
コード長 1,083 bytes
コンパイル時間 1,566 ms
コンパイル使用メモリ 166,676 KB
実行使用メモリ 5,472 KB
最終ジャッジ日時 2023-08-15 13:26:47
合計ジャッジ時間 3,609 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 3 ms
5,220 KB
testcase_01 AC 2 ms
5,156 KB
testcase_02 AC 3 ms
5,324 KB
testcase_03 AC 3 ms
5,212 KB
testcase_04 AC 3 ms
5,176 KB
testcase_05 AC 4 ms
5,216 KB
testcase_06 AC 3 ms
5,312 KB
testcase_07 AC 4 ms
5,392 KB
testcase_08 AC 3 ms
5,112 KB
testcase_09 AC 4 ms
5,328 KB
testcase_10 AC 4 ms
5,200 KB
testcase_11 AC 3 ms
5,108 KB
testcase_12 AC 4 ms
5,172 KB
testcase_13 AC 3 ms
5,176 KB
testcase_14 AC 4 ms
5,264 KB
testcase_15 AC 3 ms
5,112 KB
testcase_16 AC 3 ms
5,176 KB
testcase_17 AC 4 ms
5,472 KB
testcase_18 AC 4 ms
5,376 KB
testcase_19 AC 4 ms
5,424 KB
testcase_20 AC 4 ms
5,180 KB
testcase_21 AC 4 ms
5,212 KB
testcase_22 AC 3 ms
5,268 KB
testcase_23 AC 4 ms
5,300 KB
testcase_24 AC 2 ms
5,248 KB
testcase_25 AC 4 ms
5,428 KB
testcase_26 AC 4 ms
5,312 KB
testcase_27 AC 3 ms
5,324 KB
testcase_28 AC 4 ms
5,216 KB
testcase_29 AC 3 ms
5,316 KB
testcase_30 AC 4 ms
5,180 KB
testcase_31 AC 2 ms
5,112 KB
testcase_32 AC 65 ms
5,268 KB
testcase_33 AC 65 ms
5,268 KB
testcase_34 AC 66 ms
5,172 KB
testcase_35 AC 64 ms
5,252 KB
testcase_36 AC 66 ms
5,220 KB
testcase_37 AC 63 ms
5,372 KB
testcase_38 AC 3 ms
5,108 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<bits/stdc++.h>
using namespace std;
#define int long long
#define REP(i,m,n) for(int i=(m);i<(n);i++)
#define rep(i,n) REP(i,0,n)
#define pb push_back
#define all(a) a.begin(),a.end()
#define rall(c) (c).rbegin(),(c).rend()
#define mp make_pair
#define endl '\n'
#define vec vector<ll>
#define mat vector<vector<ll> >
#define fi first
#define se second
typedef long long ll;
typedef unsigned long long ull;
typedef pair<ll,ll> pll;
typedef long double ld;
typedef complex<double> comp;
const ll inf=1e9+7;
const ll mod=1e9+7;
const int MAX=300010;

vector<long long> mindiv(MAX);
void osa_k(){
    mindiv[1]=1;
    for(long long i=2;i<=MAX;i++){
        if(mindiv[i]>0)continue;
        long long k=1;
        while(k*i<MAX){
            if(mindiv[k*i]==0)mindiv[i*k]=i;
            k++;
        }
    }
}

signed main(){
    ll n,m;cin>>n>>m;
    bool f=1;
    ll now=0;
    ll la=0;
    rep(i,m){
        ll t,p;cin>>t>>p;
        if(abs(p-now)>t-la)f=0;
        la=t;
        now=p;
    }
    if(f){
        cout<<"Yes"<<endl;
    }else{
        cout<<"No"<<endl;
    }
}
0