In "The Pit and the Pendulum," by Edgar Allan Poe, our narrator has been tried and convicted of some crime. His punishment is death, but he does not know the method that will be used. He soon finds out when he awakens in a dark room with a slimy floor and what appears to be a bottomless pit below him. After eating and drinking, he falls into a drugged sleep and when he awakes, he is tied down with bandages, all but one arm, with a razor sharp pendulum swinging closer and closer to him from above. The narrator uses his free arm to smear the left over food over his bandages, so that the many rats in the room will eat through the bandages and free him. Once he is free, he realizes he is being watched, and next the burning walls begin to close in on him.
The resolution comes just as death is imminent. Suddenly, he is freed. This story takes place during the Spanish Inquisition when people were subject to all kinds of horrendous tortures. The ending of Poe's story is also the end of the Inquisition.