...one of the players correctly guesses the ending/puzzle/secret bad guy right from the start.
Has nothing to do with D&D.
Here's an example.
I was running a game of Classic Deadlands - a "Weird West" game, with magic and steampunk superscience. The PCs had been on the right side of a conflict, but were asked to get out Dodge (literally, they were in Dodge City, KS) for a while on principle that maybe they should have let the Sheriff handle the ruckus.
So, the party goes a wandering. They wandered into a wide spot in the road that had a saloon, a bar, a general store, and a bank that had just gotten robbed. The safe door (the place wasn't big enough for a vault) had been literally ripped of its hinges, and the horse tracks from the escape just stopped dead in the grass about a mile out of town. Townfolk, being a superstitious lot, thought ghosts robbed the bank.
The group's mad scientist character pipes up, "Ghosts don't exist! But maybe it was like, a carnival sideshow act - the strongman ripped the door off the safe, and they had a horse tamer that had trained the horses to be picked up off the open prairie by a specially modified dirigible airship!"
Of course, the only thing he was wrong about was ghosts. They did exist, but didn't rob the bank. But the rest he was totally right on.