Created
October 28, 2019 15:13
-
-
Save Epithumia/2939bf0973e3a9bfe9323a5bee1f2431 to your computer and use it in GitHub Desktop.
Solveur de l'énigme Engrenages
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
moves = [12, 15, 15, 27, 36, 42, 33, 42, 15, 18, 9] | |
wheel = ['O', 'Y', 'F', 'S', 'R', 'T', 'K', 'M', 'I', 'B', 'N', 'V', 'E', 'Z', 'G', 'U', 'T', 'A', 'Q', 'D', 'L', 'W', 'J', 'S', 'A', 'L', 'N', 'C', 'P', 'X', 'H', 'E'] | |
word = [] | |
key = 0 | |
for m in moves: | |
key += int(m*4/3) | |
word.append(wheel[key%32]) | |
print(''.join(word)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment