Mastermind is typically a two-player game, with one player acting as the codemaker and the other as the codebreaker. However, it can also be played solo, with the player attempting to guess the code set by the game itself.