답안 #938977

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
938977 2024-03-06T02:21:46 Z irmuun 디지털 회로 (IOI22_circuit) C++17
2 / 100
375 ms 7000 KB
#include<bits/stdc++.h>
#include "circuit.h"

using namespace std;

#define ll long long
#define pb push_back
#define ff first
#define ss second
#define all(s) s.begin(),s.end()
#define rall(s) s.rbegin(),s.rend()

const int mod=1000002022;

const int maxn=2e5;
vector<int>adj[maxn];
vector<int>a;
int n,m;

void init(int N,int M,vector<int>p,vector<int>A){
    n=N;
    m=M;
    a=A;
    for(int i=1;i<n+m;i++){
        adj[p[i]].pb(i);
    }
}

int count_ways(int l,int r){
    if(n==1){
        l-=n;
        r-=n;
        int cnt=0;
        for(int i=0;i<m;i++){
            if(l<=i&&i<=r){
                a[i]=1-a[i];
            }
            cnt+=a[i];
        }
        return cnt;
    }
    return 0;
}
# 결과 실행 시간 메모리 Grader output
1 Correct 2 ms 5204 KB Output is correct
2 Correct 1 ms 4952 KB Output is correct
3 Correct 1 ms 4952 KB Output is correct
4 Correct 1 ms 4952 KB Output is correct
5 Correct 2 ms 4952 KB Output is correct
6 Correct 1 ms 4952 KB Output is correct
7 Correct 2 ms 4952 KB Output is correct
8 Correct 1 ms 4952 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 4952 KB Output is correct
2 Incorrect 1 ms 4952 KB 1st lines differ - on the 1st token, expected: '52130940', found: '0'
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 2 ms 5204 KB Output is correct
2 Correct 1 ms 4952 KB Output is correct
3 Correct 1 ms 4952 KB Output is correct
4 Correct 1 ms 4952 KB Output is correct
5 Correct 2 ms 4952 KB Output is correct
6 Correct 1 ms 4952 KB Output is correct
7 Correct 2 ms 4952 KB Output is correct
8 Correct 1 ms 4952 KB Output is correct
9 Correct 1 ms 4952 KB Output is correct
10 Incorrect 1 ms 4952 KB 1st lines differ - on the 1st token, expected: '52130940', found: '0'
11 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 375 ms 7000 KB 1st lines differ - on the 1st token, expected: '431985922', found: '0'
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 375 ms 7000 KB 1st lines differ - on the 1st token, expected: '431985922', found: '0'
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 4952 KB Output is correct
2 Incorrect 1 ms 4952 KB 1st lines differ - on the 1st token, expected: '52130940', found: '0'
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 2 ms 5204 KB Output is correct
2 Correct 1 ms 4952 KB Output is correct
3 Correct 1 ms 4952 KB Output is correct
4 Correct 1 ms 4952 KB Output is correct
5 Correct 2 ms 4952 KB Output is correct
6 Correct 1 ms 4952 KB Output is correct
7 Correct 2 ms 4952 KB Output is correct
8 Correct 1 ms 4952 KB Output is correct
9 Correct 1 ms 4952 KB Output is correct
10 Incorrect 1 ms 4952 KB 1st lines differ - on the 1st token, expected: '52130940', found: '0'
11 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 2 ms 5204 KB Output is correct
2 Correct 1 ms 4952 KB Output is correct
3 Correct 1 ms 4952 KB Output is correct
4 Correct 1 ms 4952 KB Output is correct
5 Correct 2 ms 4952 KB Output is correct
6 Correct 1 ms 4952 KB Output is correct
7 Correct 2 ms 4952 KB Output is correct
8 Correct 1 ms 4952 KB Output is correct
9 Correct 1 ms 4952 KB Output is correct
10 Incorrect 1 ms 4952 KB 1st lines differ - on the 1st token, expected: '52130940', found: '0'
11 Halted 0 ms 0 KB -