Last active
July 26, 2016 15:41
-
-
Save zachpendleton/9a2d30507b1ae19c8b863fa005e18814 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| require "json" | |
| $stdin.sync = true | |
| $stdout.sync = true | |
| loop do | |
| game_state = JSON.parse(gets) | |
| row_height = game_state["board"].length | |
| column_width = game_state["board"][0].length | |
| if game_state["winner"] | |
| break | |
| end | |
| puts rand(column_width) | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment