The Mikado is an opera by Gilbert and Sullivan.
A mysterious wandering minstrel named Nanki-Poo turns up in the Japanese town of Titipu, searching for his love, Yum-Yum, the young ward of tailor-turned-Lord High Executioner Ko-Ko. Ko-Ko's in desperate need of someone to kill, because if he does not execute someone within the month, the Mikado has decreed that Titipu gets demoted to the rank of a village, and his situation would see him executed first (he was only appointed LHE so that the Mikado would not execute him for flirting); Nanki-Poo, on the run from the court of his father, the Mikado, because an amorous old woman, Katisha, wants to get in his pants (all of which he reveals to Yum-Yum), and depressed over losing Yum-Yum, decides to commit suicide. Ko-Ko, discovering this, cuts a deal with Nanki-Poo—Nanki-Poo marries Yum-Yum for one month, and at the end of this month, he gets executed, and Ko-Ko marries the young widow. Win win, yes?
Not in a Gilbert & Sullivan musical. Katisha arrives on the scene, and, after being thwarted once by the villagers in her plan to marry Nanki-Poo, storms off to bring the Mikado to Titipu. Meanwhile, Ko-Ko and his right-hand man, Poo-Bah, discover a twist in the law that if a husband is executed, his wife is buried alive—and this would be Yum-Yum's fate if the agreement were to go ahead. Ko-Ko, refusing to execute Nanki-Poo on the spot, sends the young couple away to get married, and he, Poo-Bah, and noble lord Pish-Tush present an affidavit to the Mikado detailing Nanki-Poo's death—only to find that the Mikado is searching for his son, Nanki-Poo, and that the penalty for killing the heir apparent is "something lingering, with boiling oil... or melted lead." How will Ko-Ko, Poo-Bah, Pish-Tush, Nanki-Poo and Yum-Yum ever get out of this?