The Adventures of Tom Sawyer is a novel about a young boy growing up along the Mississippi River. It is set in the 1840s in the fictional town of St. Petersburg, inspired by Hannibal, Missouri, where Twain lived as a boy. In the novel Tom Sawyer has several adventures, often with his friend, Huckleberry Finn. Originally a commercial failure, the book ended up being the best selling of any of Twain's works during his lifetime. Although The Adventures of Tom Sawyer is sometimes overshadowed by its sequel, Adventures of Huckleberry Finn, the book is considered a masterpiece of American literature, and was one of the first novels to be written on a typewriter.