If you were a pirate trying to steal gold from other pirates, what would you do? If you were forced to deduce the color of your friend's hat to escape an eccentric magician, how might counting help?