답안 #252393

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
252393 2020-07-25T12:48:37 Z orgiooo 이상한 기계 (APIO19_strange_device) C++14
10 / 100
5000 ms 524292 KB
#include <bits/stdc++.h>
#define ll long long
#define pb push_back
#define ret return 0
#define con continue
#define db double
#define gcd __gcd
#define freopen freopen("input.txt","r",stdin); freopen("output.txt","w",stdout);
using namespace std;
ll n,m,z,u,r,l,ans,h,k,y,x,t,a[10011001],b[1234567],c[1234][567];
ll i,j;
ll e[865776],g[477575];ll d[986667];
ll lcm(ll x,ll y){
    ll z=gcd(x,y);
    return x*y/z;
}
ll gcdgur(ll x ,ll y,ll z){
    return gcd(x,gcd(y,z));
}
map <string ,ll>  f;
queue <ll> que;
//multiset<int> s;
vector <ll> vec, vec1,ansvec;
set <pair<ll,ll>> s;
set<int>::iterator it;
string p,q,w;
int main(){
    ll A,B;
    cin>>n>>A>>B;
    while (n--){
        cin>>l>>r;
        
        for(i=l;i<=r;i++){
            s.insert({(i+(i/B))%A,i%B});
        }
        
    }
    cout<<s.size();
}
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Correct 62 ms 12664 KB Output is correct
3 Correct 87 ms 18296 KB Output is correct
4 Correct 2 ms 896 KB Output is correct
5 Correct 1 ms 384 KB Output is correct
6 Correct 1 ms 384 KB Output is correct
7 Correct 1 ms 512 KB Output is correct
8 Correct 1 ms 384 KB Output is correct
9 Correct 8 ms 1280 KB Output is correct
10 Correct 0 ms 384 KB Output is correct
11 Correct 0 ms 384 KB Output is correct
12 Correct 0 ms 384 KB Output is correct
13 Correct 1 ms 384 KB Output is correct
14 Correct 0 ms 384 KB Output is correct
15 Correct 41 ms 7032 KB Output is correct
16 Correct 55 ms 7288 KB Output is correct
17 Correct 234 ms 10360 KB Output is correct
18 Correct 1 ms 384 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Runtime error 3547 ms 524292 KB Execution killed with signal 9 (could be triggered by violating memory limits)
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Correct 137 ms 32376 KB Output is correct
3 Correct 182 ms 32120 KB Output is correct
4 Correct 123 ms 30712 KB Output is correct
5 Execution timed out 5066 ms 62584 KB Time limit exceeded
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Correct 2277 ms 79160 KB Output is correct
3 Runtime error 2025 ms 524288 KB Execution killed with signal 9 (could be triggered by violating memory limits)
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Correct 2277 ms 79160 KB Output is correct
3 Runtime error 2025 ms 524288 KB Execution killed with signal 9 (could be triggered by violating memory limits)
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Correct 2277 ms 79160 KB Output is correct
3 Runtime error 2025 ms 524288 KB Execution killed with signal 9 (could be triggered by violating memory limits)
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Runtime error 1610 ms 524292 KB Execution killed with signal 9 (could be triggered by violating memory limits)
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 384 KB Output is correct
2 Correct 62 ms 12664 KB Output is correct
3 Correct 87 ms 18296 KB Output is correct
4 Correct 2 ms 896 KB Output is correct
5 Correct 1 ms 384 KB Output is correct
6 Correct 1 ms 384 KB Output is correct
7 Correct 1 ms 512 KB Output is correct
8 Correct 1 ms 384 KB Output is correct
9 Correct 8 ms 1280 KB Output is correct
10 Correct 0 ms 384 KB Output is correct
11 Correct 0 ms 384 KB Output is correct
12 Correct 0 ms 384 KB Output is correct
13 Correct 1 ms 384 KB Output is correct
14 Correct 0 ms 384 KB Output is correct
15 Correct 41 ms 7032 KB Output is correct
16 Correct 55 ms 7288 KB Output is correct
17 Correct 234 ms 10360 KB Output is correct
18 Correct 1 ms 384 KB Output is correct
19 Correct 0 ms 384 KB Output is correct
20 Runtime error 3547 ms 524292 KB Execution killed with signal 9 (could be triggered by violating memory limits)
21 Halted 0 ms 0 KB -