Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
.
https://github.com/MoonPresident/Latin-Square-Generator
Calling "generate_latin_square" will generate a solution, and calling "cull_latin_square" will generate a problem. Passing the solution into "get_tower_clues" will give you the hints that surround the problem.
Incidentally, I have updated the code to go up to 15x15.
If your solution for the 6x6 would also pass the 7x7, you have a solution that is too fast for this kata.
"should" and "would" are matter of style, and therefore personal preference.
Don't know if I'm doing it wrong, but the way I wrote it, I should theoretically directly apply 7 to my function and it would solve that as well. I mean do any principles actually change by the size?
Hi Sandro, I have changed the problem set. Its more diverse but also potentially more difficult, however it should have removed the particular problems that were causing you difficulty. If you have another go, please let me know how you find it.
Hi Sandro, I can confirm that these test cases have a single valid solution using my algorithm.
Hi Sandro. The 11 by 11's are fairly computationaly expensive. I am intending to optimise the backend of this puzzle to give the frontend more time to run, if you read down through this post you will see that there are some problems uploading C++ vectors that I need to work out.
My generation algorithm was designed to only output a problem with a single valid solution. I will test those specific examples locally and get back to you.
I had to make my own Latin Square generator and then cull numbers and check whether the square was still solvable. I will look into putting my Latin square generator onto a public github.
yeah sure (but you might change your mind after seeing the test suite... ;o )
Of course, as you please. It's just a way of bounding logic together for good readability
Kata description already says "All input is valid".