-
-
Save mukeshsolanki/34b43d51336d2f98278675663785f535 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val newPosition = it.snake.first().let { poz -> | |
mutex.withLock { | |
Pair( | |
(poz.first + move.first + BOARD_SIZE) % BOARD_SIZE, | |
(poz.second + move.second + BOARD_SIZE) % BOARD_SIZE | |
) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment