Code a la Mode - Puzzle Discussion

I really liked the fact that for a few days during contest you didn’t get a random battle automatically loaded. Can we please have that as an option? Disable autoload of random battle, that is.

6 Likes

I’m interested to know more about this. That auto-play can be closed by clicking on the title or when opening any other battle. Is it because you want more space for the battles or is it because it makes your computer too slow?

As another fan of that feature (no auto-display), I would say both. The battle displayed is very rarely relevant at all to what I’m interested in, so why bother loading it? I’m also quite sure it is the main culprit causing the whole page to crash eventually, as it seemed directly linked to the number of times the tab is opened.

3 Likes

The first thing I do when I open “Last Battles” is to close the auto-loaded battle!

Actually there are other changes which would be worth to implement on this tab as already mentioned in other posts:

  • be able to see a draw match as a draw instead of a defeat,
  • be able to see matches which ended with a timeout.

My main use of “Last Battles” is to open all matches I lost to see if there was a timeout. I’m also interested in the final scores to see if there was a big range (if so I may investigate the game further).

8 Likes

That autoplay is basically like automatically opening a random page in my saved bookmarks. All i want is to look for specific page in my bookmark list, but if the bookmark button opens a random tab before i can even have a look at the list of bookmarks then it gets really annoying to have to close it and then have a look at the list.

Random battle can mean i get to see either a draw a win or a loss. Maybe i only want to check one category, or maybe i want to check only battles vs boss. There’s no scenario where i want to check random battles, which is why it’s better to make it optional and not automatically turned on.

I get the same frequent non-reproducible timeouts that I got during the contest

Meanwhile, I checked with property-based testing a la “quickcheck” that there are no exceptions during reading, parsing, and turn selection.
Still, the submitted bot has frequent, non-reproducible first-turn timeouts.
On my computer, I measured a maximal runtime of 9ms for the first turn and 8.5ms for later turns on a “cold” JVM (code was not run before and the maximum is from 10000 repetitions).
Most of the time, there is not even debug output from STDERR available although the main method starts with printing to STDERR.

(The tested and currently submitted Bot version actually picks moves in contrast to the version reported previously during the contest which just WAITed.)

I suspect a bug in the timeout detection and there is definitely a bug in handling STDERR output on timeouts because I do not get any most of the time.

I’ve pinged the devs about your issue (that you reported during the contest and a few days ago in another post). Another Clojure player had the same issue during Xmas Rush.

Thank you.

Hi all!

There are wrong inputs in the JS starter kit:

  1. numTablesWithItems has a value of 0. Given that the next loop is based on it, this loop never executes.
  2. Inside the loop, the variables tableX, tableY and item have irrelevant values.

This makes the challenge impossible to solve in JS.
May someone fix it please ?:slightly_smiling_face:

The inputs aren’t based on the starter kits, the game gives you the inputs.
It is correct that on your first round, no table has any item on it. Instead, the corresponding crates are marked as “B” and “I” in the grid (Which is read in lines 117-120 in the starter).
You get the corresponding crates by using the function getCellFromType in GAME.grid

Later on in the game, tables may have items on them, only then numTablesWithItems will have a value greater than 0.

2 Likes

hey,

@Anti Squid, thanks for posting this topic and thank you all for your replies. It was quiet informative and helped me a lot with my 192.168.0.254 IP router panel as i was also having the same issue.

Best regards!!!

The inputs aren’t based on the starter kits, the game gives you the inputs.

Yeah, this is so logical that I don’t know why I focused on the starter kit.

Thank you for this clear answer !

Hi all !
I’m facing a very frustrating problem in this game : I’m OK for the coop side, but almost everytime
I drop a dish on the table just to take strawberries and chop them, the AI gets back my plate before me.
It wouldn’t bother me if I earned some points, but it seems not to be the case.

Maybe I miss something, or got something wrong in the instrrctions.

an all likelyhood, you test your code in the IDE against the same AIs (the boss) which behave the same way. However, losing against the boss AI in the IDE doesn’t mean your AI is necessarily bad. When you submit your code, your AI plays matches against different kind of AIs and strategies, so you can potentially score higher than the boss even if you lose all your matches against it.

Now, if an AI is doing an action that disturbs your AI, then you must update your AI so it adapts to any situation.

Thanks @TwoSteps, I guess those are words of wisdom !
So I’m gonna handle this “greedy partner” problem.

I am in the starter-League and have a Question:

Is ‘DISH-ICE_CREAM-BLUEBERRIES’ the same order/item as ‘DISH-BLUEBERRIES-ICE_CREAM’ ?

does it matter in what order i collect stuff?

The item order does not matter in the DISH name, your two examples are indeed the same. You can collect items in the order of your choice.

2 Likes

Bonjour,

Je parle français car le bug ne concernent que les français.

Il y une petite erreur dans l’énoncé de Coding Games and Programming Challenges to Code Better en ligue bronze.

« Pour préparer une tarte aux myrtilles, il faut couper la pâte à la planche à écouper »

Il faut dire planche à découper.

Bonne journée,
Vincent

1 Like

Hi,

Another little bug in the referee. It says “Cannot take TART while holding STRAWBERRIES!” but it should be the opposite: Cannot take STRAWBERRIES while holding TART!

Thanks for the game though!

2 Likes

If your partner deactivates for any reason, their position is reported as -1,-1. This was throwing wrenches into my wood 2 bot until I tracked it down. It would be nice to have that mentioned in the description.