Number reversal game: Difference between revisions
Content added Content deleted
Line 112: | Line 112: | ||
while data != sort data: |
while data != sort data: |
||
trials += 1 |
trials += 1 |
||
flip = int input '#$trials: LIST: ${join data} Flip how many?: ' |
flip = int input '#${trials}: LIST: ${join data} Flip how many?: ' |
||
data[:flip] = data[ |
data[:flip] = reverse data[:flip] |
||
print '\nYou took $trials attempts to put digits in order!' |
print '\nYou took ${trials} attempts to put digits in order!'</lang> |
||
</lang> |
|||
=={{header|AutoHotkey}}== |
=={{header|AutoHotkey}}== |