from axelrod.action import Action
from axelrod.player import Player
lllIlIIIl, lIIlIIIIlllIIIllllII = Action.C, Action.D
class lIIlllIlIII(Player):
    lIIIllIlIlI = "strategy"
    IIIlIlIllI = {
        "memory_depth": float("inf"),  
        "stochastic": False,
        "long_run_time": False,
        "inspects_source": False,
        "manipulates_source": False,
        "manipulates_state": False,
    }
    def llIlllIIlIlIllII(lllIIllllIllII, IllIIIllllllIIllII: Player) -> Action:
        if (
            IllIIIllllllIIllII.history.cooperations > 0
            and IllIIIllllllIIllII.history[-3:] == [lIIlIIIIlllIIIllllII] * 3
        ):
            return lllIlIIIl
        return lIIlIIIIlllIIIllllII