Tragicomedy is a literary genre that blends aspects of both tragic and comic forms. Most often seen in dramatic literature, the term can describe either a tragic play which contains enough comic elements to lighten the overall mood or a serious play with a happy ending. Tragicomedy, as its name implies, invokes the intended response of both the tragedy and the comedy in the audience, the former being a genre based on human suffering that invokes an accompanying catharsis and the latter being a genre intended to be humorous or amusing by inducing laughter.
Tragic Comic masks of Ancient Greek theatre represented in the Hadrian's Villa mosaic.
A literary genre is a category of literature. Genres may be determined by literary technique, tone, content, or length. They generally move from more abstract, encompassing classes, which are then further sub-divided into more concrete distinctions. The distinctions between genres and categories are flexible and loosely defined, and even the rules designating genres change over time and are fairly unstable.
"Allegories of literary genre" by Constant Montald (1899)