Don't Panic - Episode 1 - Puzzle discussion


I can't pass the first validation test.
Either the clone got destroy either it is blocked on the generator so no other clone can spawn .... i don't get it ...
Can someone explain me ?

Edit :
ok, nevermind the problem was this rule :

If there is no leading clone, the line values are: -1 -1 NONE. This can happen only when the clones which are already outside are all blocked and the next clone is not out yet. In this case, you may output action WAIT.


I'm using Python3 and having the same issue. There is something that i'm not understanding about how to reference the relevant elevator_pos value. I tried this for getting the direction but it gave an error:
if clone_pos < elevator_pos[elevator_floor.index(clone_floor)]:
elevatorDir = 'RIGHT'
elevatorDir = 'LEFT'


Hello, I always have an error with the "U Turn" test after submitting my response. The error is "Timeout: the program did not provide 1 input lines in due time...", but I've already added a output "WAIT" when the only head is blocked. Can someone help? Thanks


Timeout means one of three things.
1) You took too long to think about the answer (generally this means > 100ms)
2) Your program crashed. Millions of ways for this to happen.
3) You didn't give an answer. Example in pseudocode:

if value < 3 then answer = 1
if value > 3 then answer = 2
value turns out to be 3, no answer is given.

One of those things is probably true in your code.


I solved the problem, thank you.


Thanks for info - helped me to solve :wink:


The animation and the layout were cool. Fun visuals


Anyone an idea what caused it/ how to fix it? Didn’t change anything from the input lines.
Standard Error Stream:

Exception in thread "main" java.util.InputMismatchException

at java.util.Scanner.throwFor on line 864

at on line 1485

at java.util.Scanner.nextInt on line 2117

at java.util.Scanner.nextInt on line 2076

at Player.main on line 32'


Yes you did :stuck_out_tongue:

Here’s the part you changed:

for (int i = 0; i < nbElevators; i++) {
      int elevatorFloor = in.nextInt(); // floor on which this elevator is found
      int elevatorPos = in.nextInt(); // position of the elevator on its floor