답안 #888648

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
888648 2023-12-18T05:01:54 Z Sir_Ahmed_Imran 저장 (Saveit) (IOI10_saveit) C++17
0 / 100
196 ms 20500 KB
                              ///~~~LOTA~~~///
#include "grader.h"
#include <bits/stdc++.h>
using namespace std;
void encode(int n,int m,int p,int a[],int b[]){
    int o;
    int d[m][n];
    bool vis[n];
    vector<int> e[n];
    for(int i=0;i<p;i++){
        e[a[i]].push_back(b[i]);
        e[b[i]].push_back(a[i]);
    }
    for(int i=0;i<m;i++){
        for(int j=o=0;j<n;j++)
            vis[j]=1;
        vector<int> u,v{i};
        while(!v.empty()){
            for(auto& j:v){
                d[i][j]=o;
                for(auto& k:e[j]){
                    if(vis[k])
                        u.push_back(k);
                    vis[k]=0;
                }
            }
            o++;
            v=u;
            u.clear();
        }
    }
    for(int i=0;i<m;i++){
        for(int j=0;j<n;j++){
            for(int k=512;k>0;k/=2){
                if(d[i][j]>=k){
                    encode_bit(1);
                    d[i][j]-=k;
                }
                else encode_bit(0);
            }
        }
    }
}
                              ///~~~LOTA~~~///
#include "grader.h"
#include <bits/stdc++.h>
using namespace std;
void decode(int n,int m){
    int o;
    for(int i=0;i<m;i++){
        for(int j=0;j<n;j++){
            o=0;
            for(int k=512;k>0;k/=2){
                if(decode_bit()) o+=k;
            }
            hops(i,j,o);
        }
    }
}
# 결과 실행 시간 메모리 Grader output
1 Incorrect 196 ms 20500 KB Output isn't correct
2 Incorrect 2 ms 11268 KB Output isn't correct
3 Incorrect 47 ms 15708 KB Output isn't correct
4 Incorrect 2 ms 11108 KB Output isn't correct
5 Incorrect 56 ms 15624 KB Output isn't correct
6 Incorrect 60 ms 16236 KB Output isn't correct
7 Incorrect 67 ms 16020 KB Output isn't correct
8 Incorrect 51 ms 15648 KB Output isn't correct
9 Incorrect 55 ms 15676 KB Output isn't correct
10 Incorrect 61 ms 15472 KB Output isn't correct
11 Incorrect 61 ms 15840 KB Output isn't correct
12 Incorrect 63 ms 15624 KB Output isn't correct
13 Incorrect 69 ms 16172 KB Output isn't correct
14 Incorrect 56 ms 15616 KB Output isn't correct
15 Incorrect 55 ms 15508 KB Output isn't correct
16 Incorrect 74 ms 16244 KB Output isn't correct
17 Incorrect 71 ms 15956 KB Output isn't correct
18 Incorrect 75 ms 16592 KB Output isn't correct
19 Incorrect 60 ms 15928 KB Output isn't correct
20 Incorrect 76 ms 18548 KB Output isn't correct
21 Incorrect 100 ms 18612 KB Output isn't correct
22 Incorrect 80 ms 16072 KB Output isn't correct
23 Incorrect 87 ms 18756 KB Output isn't correct
# 결과 실행 시간 메모리 Grader output
1 Incorrect 196 ms 20500 KB Output isn't correct
2 Incorrect 2 ms 11268 KB Output isn't correct
3 Incorrect 47 ms 15708 KB Output isn't correct
4 Incorrect 2 ms 11108 KB Output isn't correct
5 Incorrect 56 ms 15624 KB Output isn't correct
6 Incorrect 60 ms 16236 KB Output isn't correct
7 Incorrect 67 ms 16020 KB Output isn't correct
8 Incorrect 51 ms 15648 KB Output isn't correct
9 Incorrect 55 ms 15676 KB Output isn't correct
10 Incorrect 61 ms 15472 KB Output isn't correct
11 Incorrect 61 ms 15840 KB Output isn't correct
12 Incorrect 63 ms 15624 KB Output isn't correct
13 Incorrect 69 ms 16172 KB Output isn't correct
14 Incorrect 56 ms 15616 KB Output isn't correct
15 Incorrect 55 ms 15508 KB Output isn't correct
16 Incorrect 74 ms 16244 KB Output isn't correct
17 Incorrect 71 ms 15956 KB Output isn't correct
18 Incorrect 75 ms 16592 KB Output isn't correct
19 Incorrect 60 ms 15928 KB Output isn't correct
20 Incorrect 76 ms 18548 KB Output isn't correct
21 Incorrect 100 ms 18612 KB Output isn't correct
22 Incorrect 80 ms 16072 KB Output isn't correct
23 Incorrect 87 ms 18756 KB Output isn't correct
# 결과 실행 시간 메모리 Grader output
1 Incorrect 196 ms 20500 KB Output isn't correct
2 Incorrect 2 ms 11268 KB Output isn't correct
3 Incorrect 47 ms 15708 KB Output isn't correct
4 Incorrect 2 ms 11108 KB Output isn't correct
5 Incorrect 56 ms 15624 KB Output isn't correct
6 Incorrect 60 ms 16236 KB Output isn't correct
7 Incorrect 67 ms 16020 KB Output isn't correct
8 Incorrect 51 ms 15648 KB Output isn't correct
9 Incorrect 55 ms 15676 KB Output isn't correct
10 Incorrect 61 ms 15472 KB Output isn't correct
11 Incorrect 61 ms 15840 KB Output isn't correct
12 Incorrect 63 ms 15624 KB Output isn't correct
13 Incorrect 69 ms 16172 KB Output isn't correct
14 Incorrect 56 ms 15616 KB Output isn't correct
15 Incorrect 55 ms 15508 KB Output isn't correct
16 Incorrect 74 ms 16244 KB Output isn't correct
17 Incorrect 71 ms 15956 KB Output isn't correct
18 Incorrect 75 ms 16592 KB Output isn't correct
19 Incorrect 60 ms 15928 KB Output isn't correct
20 Incorrect 76 ms 18548 KB Output isn't correct
21 Incorrect 100 ms 18612 KB Output isn't correct
22 Incorrect 80 ms 16072 KB Output isn't correct
23 Incorrect 87 ms 18756 KB Output isn't correct
# 결과 실행 시간 메모리 Grader output
1 Incorrect 196 ms 20500 KB Output isn't correct
2 Incorrect 2 ms 11268 KB Output isn't correct
3 Incorrect 47 ms 15708 KB Output isn't correct
4 Incorrect 2 ms 11108 KB Output isn't correct
5 Incorrect 56 ms 15624 KB Output isn't correct
6 Incorrect 60 ms 16236 KB Output isn't correct
7 Incorrect 67 ms 16020 KB Output isn't correct
8 Incorrect 51 ms 15648 KB Output isn't correct
9 Incorrect 55 ms 15676 KB Output isn't correct
10 Incorrect 61 ms 15472 KB Output isn't correct
11 Incorrect 61 ms 15840 KB Output isn't correct
12 Incorrect 63 ms 15624 KB Output isn't correct
13 Incorrect 69 ms 16172 KB Output isn't correct
14 Incorrect 56 ms 15616 KB Output isn't correct
15 Incorrect 55 ms 15508 KB Output isn't correct
16 Incorrect 74 ms 16244 KB Output isn't correct
17 Incorrect 71 ms 15956 KB Output isn't correct
18 Incorrect 75 ms 16592 KB Output isn't correct
19 Incorrect 60 ms 15928 KB Output isn't correct
20 Incorrect 76 ms 18548 KB Output isn't correct
21 Incorrect 100 ms 18612 KB Output isn't correct
22 Incorrect 80 ms 16072 KB Output isn't correct
23 Incorrect 87 ms 18756 KB Output isn't correct