提出 #76651076


ソースコード 拡げる

#include<bits/stdc++.h>
using namespace std;

int n;
vector<pair<int,int>> p;
int ans;
int mn;

signed main(){
    scanf("%d",&n);
    p.resize(n);
    for(int i=0;i<n;++i)scanf("%d%d",&p[i].first,&p[i].second);
    sort(p.begin(),p.end());
    mn=1e9;
    ans=0;
    for(int i=0;i<n;++i){
        if(p[i].second<mn)++ans;
        if(p[i].second<mn)mn=p[i].second;
    }
    printf("%d\n",ans);
    return 0;
}

提出情報

提出日時
問題 C - Not Covered Points
ユーザ Chen_Zhen_DY
言語 C++23 (Clang 21.1.0)
得点 300
コード長 431 Byte
結果 AC
実行時間 51 ms
メモリ 5200 KiB

ジャッジ結果

セット名 Sample All
得点 / 配点 0 / 0 300 / 300
結果
AC × 3
AC × 25
セット名 テストケース
Sample 00_sample_00.txt, 00_sample_01.txt, 00_sample_02.txt
All 00_sample_00.txt, 00_sample_01.txt, 00_sample_02.txt, 01_random_00.txt, 01_random_01.txt, 01_random_02.txt, 01_random_03.txt, 01_random_04.txt, 01_random_05.txt, 01_random_06.txt, 01_random_07.txt, 01_random_08.txt, 01_random_09.txt, 01_random_10.txt, 01_random_11.txt, 01_random_12.txt, 01_random_13.txt, 01_random_14.txt, 01_random_15.txt, 01_random_16.txt, 01_random_17.txt, 01_random_18.txt, 01_random_19.txt, 01_random_20.txt, 01_random_21.txt
ケース名 結果 実行時間 メモリ
00_sample_00.txt AC 1 ms 3064 KiB
00_sample_01.txt AC 1 ms 3044 KiB
00_sample_02.txt AC 1 ms 2852 KiB
01_random_00.txt AC 1 ms 3052 KiB
01_random_01.txt AC 27 ms 4992 KiB
01_random_02.txt AC 49 ms 5188 KiB
01_random_03.txt AC 26 ms 5104 KiB
01_random_04.txt AC 51 ms 4996 KiB
01_random_05.txt AC 34 ms 4500 KiB
01_random_06.txt AC 51 ms 5060 KiB
01_random_07.txt AC 28 ms 3960 KiB
01_random_08.txt AC 50 ms 4996 KiB
01_random_09.txt AC 29 ms 4300 KiB
01_random_10.txt AC 50 ms 5100 KiB
01_random_11.txt AC 15 ms 3604 KiB
01_random_12.txt AC 51 ms 4952 KiB
01_random_13.txt AC 50 ms 5188 KiB
01_random_14.txt AC 49 ms 5200 KiB
01_random_15.txt AC 50 ms 4996 KiB
01_random_16.txt AC 51 ms 4984 KiB
01_random_17.txt AC 51 ms 5104 KiB
01_random_18.txt AC 50 ms 5148 KiB
01_random_19.txt AC 51 ms 5016 KiB
01_random_20.txt AC 50 ms 5060 KiB
01_random_21.txt AC 49 ms 4952 KiB