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.
Added more test cases including random test cases. If no path is found, the solution should return [].
yes
yes
im sorry but english isnt my native language, i just don't get properly what this test is about, would it be too spoiling to give the test case? thks
Kind of, yes. But target state can be outside of the cycle.
i am not sure to get it, do you mean tests such as
processes('field', 'field', [
['gather', 'field', 'wheat'],
['bake', 'flour', 'bread'],
['mill', 'wheat', 'flour'],
['test', 'bread', 'field']
])
Math, write out the a few cases, do you notice a pattern? Then your code should try and force the other player into the position you don't want. The code that's running this definitely is just taking two instances of your class(add some System.out.println's) very easy to detect.
solved thanks but im failing at test 4 (cycles), what is it exactely ? thanks
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
The key really is who moves first!
You should find strategy, how to decrease number of cakes without giving opponent chance to win. Each your move not only shortens cakes amount, but also prevents opponent from eating same number of cakes as you.
I feel sorry for asking but I really can't get my head around this one.
And even dumber as it is apparently an easy one...
I thought about multiple approaches:
My feeling is that I should always start as that allows me to predict the opponent play except in case of really low start cakes amount.
I feel that the key lies of course in the last steps of the game, could I have some hints pls?
Apologies if I gave too much information