Nim - Rules of Play says:
Late medieval historical mathematical game; great for maths geeks. Variants of this game or mathematical puzzle are first recorded in Europe in the early 16th century, notably in the writings of Luca Pacioli, collaborator with Leonardo da Vinci and one of the founders of accountancy.