carykh / PrisonersDilemmaTournament

Watch This Place's awesome video about iterated Prisoner's Dilemma for context! https://www.youtube.com/watch?v=BOvAbjfJ0x0
MIT License
205 stars 160 forks source link

One-line strategy for amusement (possible bug?) #44

Closed t1m0thyj closed 3 years ago

t1m0thyj commented 3 years ago

Not submitting this as it obviously cheats the system, but I discovered that this simple code handily beats all the sample strategies:

def strategy(history, memory): return -2, None
carykh commented 3 years ago

Oops! That is a pretty glaring mistake I made. Yeah, strategies should only be allowed to return 0, 1, or the string-equivalent versions of those. I'll fix this very soon