In Reinforcement learning, the agent is one who takes decisions based on the rewards and punishments. Consider an example of a batsman in cricket. He tries to hit the ball if he misses he gets a negative point. If he hits the ball then he gets a reward .