Wrote a Go program to solve the Connect 4 community puzzle (https://www.codingame.com/training/hard/connect-four). Solves the four test cases, but only 3 of the validation tests. It fails on #1. I am positive my program is correct, yet it fails. How can this be? Here’s my code if you want to take a look:
It’s not the most elegant solution, but it works, mostly.
Finished the Community puzzle Connect Four. I found that the validation is not consistent in reading a Carriage Return. I am using java. When the answer is two numbers, I use println() to display it. When the answer is “NONE”, I found that println(“NONE”) does not work. I have to change it to print(“NONE”) to pass.
Weird - that could be the reason for @Dogwon and some others to fail in some tests.
Validators #1 und #2 fail. Is it still an issue with the carriage return and the ‘NONE’ answer or something else? I have tried to omit carriage return when outputting NONE (as java_coffee_cup suggested) but this doesn’t work. Anybody has an idea? Using Python3.
Hi eulerscheZahl, if this is a reply to my question: I’m sorry I don’t understand. I’m struggling with the puzzles, not yet tried anything with multiplayers
Completely by coincidence, I solved the “Connect Four” solo puzzle yesterday.
I did not encounter any problem with validations or with the expected Carriage Returns in output.
Sending the right solution with two lines of either “NONE” or the space separated list of winning x positions, (both lines with trailing CR) passes all tests.