Submission #300150

# Submission time Handle Problem Language Result Execution time Memory
300150 2020-09-16T21:36:09 Z circlethm Mechanical Doll (IOI18_doll) C++17
2 / 100
28 ms 2124 KB
#include "doll.h"
#include <vector>

using namespace std;

// Subtask 1
void create_circuit(int M, vector<int> A)
{
  int N = A.size();
  vector<int> C(M + 1);

  C[0] = A[0];
  for (int i = 0; i < N - 1; i++)
  {
    C[A[i]] = A[i + 1];
  }
  C[A[N - 1]] = 0;

  // C[0] = -1;
  // for (int i = 1; i <= M; ++i)
  // {
  //   C[i] = 1;
  // }

  vector<int> X(0), Y(0);
  // for (int k = 0; k < N; ++k)
  // {
  //   X[k] = Y[k] = A[k];
  // }
  answer(C, X, Y);
}
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 27 ms 1868 KB Output is correct
3 Correct 17 ms 1484 KB Output is correct
4 Correct 1 ms 204 KB Output is correct
5 Correct 12 ms 1356 KB Output is correct
6 Correct 26 ms 2124 KB Output is correct
7 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 27 ms 1868 KB Output is correct
3 Correct 17 ms 1484 KB Output is correct
4 Correct 1 ms 204 KB Output is correct
5 Correct 12 ms 1356 KB Output is correct
6 Correct 26 ms 2124 KB Output is correct
7 Correct 1 ms 204 KB Output is correct
8 Incorrect 28 ms 2084 KB wrong motion
9 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 27 ms 1868 KB Output is correct
3 Correct 17 ms 1484 KB Output is correct
4 Correct 1 ms 204 KB Output is correct
5 Correct 12 ms 1356 KB Output is correct
6 Correct 26 ms 2124 KB Output is correct
7 Correct 1 ms 204 KB Output is correct
8 Incorrect 28 ms 2084 KB wrong motion
9 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 204 KB wrong motion
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 204 KB wrong motion
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 204 KB wrong motion
2 Halted 0 ms 0 KB -