Submission #336668

# Submission time Handle Problem Language Result Execution time Memory
336668 2020-12-16T09:55:38 Z cheeheng Stations (IOI20_stations) C++14
8 / 100
878 ms 1012 KB
#include "stations.h"
#include <bits/stdc++.h>
using namespace std;

std::vector<int> label(int n, int k, std::vector<int> u, std::vector<int> v) {
	std::vector<int> labels(n);

	for (int i = 0; i < n; i++) {
		labels[i] = i+1;
	}
	return labels;
}

int find_next_station(int s, int t, std::vector<int> c) {
    //printf("s=%d t=%d\n", s, t);
    assert(s != t);
    for(int i = 1; i < 11; i ++){
        if(s == (t>>i)){
            return (t>>(i-1));
        }
    }

	return s>>1;
}
# Verdict Execution time Memory Grader output
1 Incorrect 529 ms 756 KB Wrong query response.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 464 ms 736 KB Output is correct
2 Correct 543 ms 844 KB Output is correct
3 Correct 878 ms 884 KB Output is correct
4 Correct 659 ms 744 KB Output is correct
5 Correct 603 ms 736 KB Output is correct
6 Correct 455 ms 736 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 536 ms 736 KB Wrong query response.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 808 ms 1012 KB Output is correct
2 Incorrect 626 ms 756 KB Wrong query response.
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 532 ms 736 KB Wrong query response.
2 Halted 0 ms 0 KB -