In William Shakespeare's Hamlet, contrast plays a major role. Characters have foils, scenes and ideas contrast each other, sometimes within the same soliloquy. One such contrast occurs in Act Five, Scene One, in the graveyard. Here, the relatively light mood in the first half is offset by the grave and somber mood in the second half.
The scene opens with two "clowns", who function as a sort of comic relief. This is necessary, after the tension of Ophelia's breakdown (and subsequent death), and after the ever-increasing complexities of the plot. Previously, Polonious provided some humour, but since he is dead, a new source must be found - the gravediggers. Their banter becomes the calm before the storm of the duel, and the play's resolution. There is also a juxtaposition of the clowns and the graveyard here, which further intensifies the effect. The clowns chatter about their work in a carefree manner, even going so far as to play with a riddle ( " What is he that builds stronger ... carpenter" V,1,41-42). Shakespeare even went so far as to include his puns in this grave scene (V,1,120).
Hamlet himself experiences a temporary lightening of mood from listening to the gravediggers' conversation. Their carefree treatment of death singing while digging graves, not to mention tossing skulls in the air) is a parallel to Hamlet's newfound attitude. After having committed himself to his cause in Act IV, he is no longer bothered by the paradox of good and evil, and (seemingly) is untroubled by his previous misgivings.
Hamlet's musings on the equality of all men in death serve as a transition into the darker second half of the scene. His contemplations on death reflect Act IV, Scene 3, when Hamlet gives voice to a humorous notion concerning " how a king may progress through the guts of a beggar " (IV,3,27-28). Hamlet expands on this idea with his thoughts on how even Alexander the Great or " Imperious...