Tell us what’s happening:
I am trying to figure out which player I am playing against in play() how should I proceed to do so? What I am thinking is that importing RPS_game.py and from its play function seeing the player_2. Is this approach right? Is there any better way?
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.90 Safari/537.36.
Count. Every game is 1,000 turns. The players should play in mostly the same order, I think.
Analyze the player’s plays. Every player plays in a distinct pattern. It should be easy to detect three of them anyway (so all of them by elimination).
There is an easier way that doesn’t involve importing the other players. I haven’t investigated if that’s feasible. But the other way is really easy…so much so that it takes the “machine” out of “machine learning.”
Play the other players against each other. One is a lot tougher than the rest. Then, read the code to see why.
Create a strategy good enough to beat them all. It’s only a recommendation that you may need to employ different strategies.