Submission #432883

# Submission time Handle Problem Language Result Execution time Memory
432883 2021-06-18T14:35:17 Z lior5654 Stations (IOI20_stations) C++17
0 / 100
870 ms 784 KB
#include <bits/stdc++.h>

using namespace std;


typedef long long int ll;
typedef pair<ll, ll> pl;
typedef vector<ll> vl;
typedef vector<vl> vvl;
typedef vector<pl> vpl;
typedef vector<vpl> vvpl;
typedef pair<int, int> pi;
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef vector<pi> vpi;
typedef vector<vpi> vvpi;

#define rep(i, n) for(int i = 0; i < n; ++i)
#define all(c) (c.begin()), (c.end())
#define pb push_back
#define eb emplace_back
#define fi first
#define se second


#include "stations.h"


const int maxn = 1e3 + 5;

vi g[maxn];


std::vector<int> label(int n, int k, std::vector<int> u, std::vector<int> v) {
    vi res(n);
    rep(i, n) {
        res[i] = i;
    }
    return res;
}

int find_next_station(int s, int t, std::vector<int> c) {
	if( t < s) {
        return *min_element(all(c));
    }
    while(t) {
        for(auto e : c) {
            if(e == t) return e;
        }
        t = (t - 1) / 2;
    }
    assert(false);

}
# Verdict Execution time Memory Grader output
1 Runtime error 3 ms 784 KB Execution killed with signal 6
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Runtime error 6 ms 784 KB Execution killed with signal 6
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Runtime error 3 ms 784 KB Execution killed with signal 6
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 870 ms 488 KB Output is correct
2 Runtime error 2 ms 760 KB Execution killed with signal 6
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Runtime error 4 ms 764 KB Execution killed with signal 6
2 Halted 0 ms 0 KB -