conclusion
"Twelfth Night" is a reference to the twelfth night after Christmas Day, called the Eve of the Feast of Epiphany. It was originally a Catholic holiday but, prior to Shakespeare's play, had become a day of revelry. Servants often dressed up as their masters, men as women and so forth. This history of festive ritual and Carnivalesque reversal, based on the ancient Roman festival of Saturnalia at the same time of year (characterized by drunken revelry and inversion of the social order; masters became slaves for a day, and vice versa), is the cultural origin of the play's gender confusion-driven plot. The source story, "Of Apolonius and Silla", appeared in Barnabe Richie’s  collection,Riche his Farewell to Militarie Profession conteining verie pleasaunt discourses fit for a peaceable tyme (1581), which in turn is derived from a story by Matteo Bandello.
In medieval and Tudor England, the Twelfth Night marked the end of a winter festival that started on All Hallows Eve — now more commonly known as Halloween. The Lord of Misrule symbolizes the world turning upside down. On this day the King and all those who were high would become the peasants and vice versa. At the beginning of the Twelfth Night festival, a cake that contained a bean was eaten. The person who found the bean would rule the feast. Midnight signaled the end of his rule and the world would return to normal. The common theme was that the normal order of things was reversed. This Lord of Misrule tradition dates back to pre-Christian European festivals such as the Celtic festival of Samhain and the Ancient Roman festival of Saturnalia.