## Hipster, Ruby if ARGV.length == 0 puts rand(2) else last_round = ARGV[0].split(',').last n_players = last_round.length puts last_round.count('1') > n_players/2 ? 0 : 1 end Simply goes with last round's minority, just because everything else is mainstream. Run like ruby hipster.rb