Run ID:121587

提交时间:2025-06-07 17:11:01

#include<bits/stdc++.h> using namespace std; int main() { int a[10001]={0},l,m,st,en,s=0; cin>>l>>m; for(iont i=0;i<m;i++) { cin>>st>>en; for(int j=st;j<=js;j++) a[j]=1; } for(int i=0;i<m;i++) { if(a[i]==0) s++; } cout<<s; return 0; }