The origin of the bet in Anton Chekhov's short story The Bet takes place on a "dark autumn night." It was then that a wealthy banker held a party in which there were many guests, including "journalists and intellectual men." The discussion centered on capital punishment, the death sentence or life imprisonment, and whether or not it was "moral." The story then continues towards the end of the first section:
Among the guests was a young lawyer, a young man of five-and-twenty. When he was asked his opinion, he said:
"The death sentence and the life sentence are equally immoral, but if I had to choose between the death penalty and imprisonment for life, I would certainly choose the second. To live anyhow is better than not at all."
A lively discussion arose. The banker, who was younger and more nervous in those days, was suddenly carried away by excitement; he struck the table with his fist and shouted at the young man:
"It's not true! I'll bet you two million you wouldn't stay in solitary confinement for five years."
"If you mean that in earnest," said the young man, "I'll take the bet, but I would stay not five but fifteen years."
"Fifteen? Done!" cried the banker. "Gentlemen, I stake two million!"
"Agreed! You stake your millions and I stake my freedom!" said the young man.
Since Chekhov was Russian, the currency was most likely rubles, while many modern translations simply insert dollars for simplicity and convenience. Now you have the origin of the bet in one of Chekhov's most popular short stories.