[Community Puzzle] Robot show

The bug ticket is still in our backlog. I’m sorry we haven’t fixed Groovy yet.

You can report issues using the contact us page: https://www.codingame.com/about/contact

1 Like

I did the exact same! It’s nice to see the animation :wink:

I get 100% my 1 solution was ok but to slow :slight_smile:

Love this puzzle. To whoever is still trying the brutal force, stop what you are doing right now. There is simple trick in this question.

Think about the example, when two bots collide with each other, it is equivalent to those two bots has bypassed each other. So the bot will travel however the length left in the tunnel!

Thanks to you @TwoSteps and all the @_CG_Team, Groovy language seems to build again :slight_smile: … so pleased :slight_smile: !

Unfortunately, as i said in the Happy Numbers forum ([Community Puzzle] Happy Numbers - #40 by Jp82), all my Tests pass successfully in Groovy, in this puzzle too … but none of the Validators :frowning: !
→ Is there another (or the same) mistake in my code ?
Thanks to anyone who can help to solve the problem :confused: !

Hi to all :slight_smile: !
As i said in this topic (Groovy gets timeouts in every clash now - #17 by Jp82) reporting the same problem, i’d like now to share the good news with all concerns in this topic too …
→ Groovy coding works now for me in both IDE and Validators :slightly_smiling_face: !
=> I’d like to thanks @anon72424297 too, involved as @TwoSteps i think, and maybe others members of the @CGTeam, because of the issues seems to be solved :clap:
Thanks a lot to anyone worked around !
=> Now time is to get fun again with Groovy coding :wink:
bye !

1 Like

hey guys

I am solving this robot show puzzle and I have solved first 2 test, I guess by luck xD. I am trying to do it in c++. I have read the forum on it but I got no hints from there. If anyone can provide me with some hints to solve this problem will be helpful.

Yeah, that solved it for me.

This is a fun puzzle :slight_smile:

Yes @Liquidor : I agree with you … and the ‘Robot show’ must go on :wink:

I have also problem with validator 5, I use half step movements, and use modulo to figure out where is the middle, but still I have problem.

Yes, I did it. Friend did give me a clue. Rather to think about bouncing robots, better is to think that they are passing each other.

Very nice idea - big like to this puzzle
“Passing the box” is indeed a clever hint

And indeed, the “EASY” describes the end solution. Reaching it involves getting “out of the box” which is anything but easy :slight_smile:

I’m stuck at the same point. (Test 2 … 19 instead of 20)

I ran the simulation with all 128 (2^7) possible direction combinations and I did not get any result with 20 seconds - maximum is 19 seconds.
@java_coffee_cup can you please provide how you get to 20 seconds??

> > > < >  <  <
1 2 6 7 10 14 20

this can be one of the possible start up designs.

1 Like

Thx for fast answer.

Since I got also only 19s with your left-right-combination I realized a that the problem must be somewhere else.

After some tries it became clear that it was connected to the robot [20] → for my understanding a bot at 20 means it is out (following the rule from the example where the bot is out when hitting 10). After considering this bot to be in everything worked fine :+1:

1 Like

Your analysis can be useful to future comers. A bot at 0 or 20 (the extreme right-hand-side) are going out if they face outwards; they are coming in if they face inwards,

My mind was BLOWN by this puzzle.
I wish it was possible to add more stars, best one I’ve made by FAR! it’s… just… wow.

1 Like

I seem to pass all test cases and haven’t hard coded anything, but I seem to not pass validator 2, 3 & 4. No clue why. Can anyone help?

    int L = int.Parse(Console.ReadLine());
    int N = int.Parse(Console.ReadLine());
    string[] inputs = Console.ReadLine().Split(' ');
    int lowest = int.Parse(inputs[0]);

    for (int i = 0; i < N; i++)
    {
        int b = int.Parse(inputs[i]);

        if(b < lowest)
        {
            lowest = b;
        }
    }
    if(N%2 == 0)
    {
        Console.WriteLine(L - lowest);
    }
    else if(N == 1)
    {
        if((lowest) > (L - lowest))
        {
            Console.WriteLine(lowest);
        }
        else
        {
            Console.WriteLine(L - lowest);
        }
    }
    else
    {
        Console.WriteLine(L - lowest + 1);
    }

Browsed it and feel that the logic does not make good sense. For example N is even or odd is designed to determine the result which seems to be a source of error.