The pigeonhole principle states that if n objects are put into m containers where n > m, then at least one container must contain more than one object. It was first described by Dirichlet in 1834 and has various applications in mathematics and computer science. Some examples include proving that among a group of people, some pair will have the same birthday, and that collisions are inevitable in a hash table where there are more possible keys than indices. The principle can be used to solve problems involving divisibility, counting, and allocation of objects into groups.