I've had a similar experience with puzzles . . . except I was the DM. And it made a very funny story, too!
So the party had time-traveled to the future and were exploring an abadoned wizard tower in the ruins of a city. Hundreds of years ago, the mage guild left the tower when they learned some horrible calamity would befall the city. They locked it up tight with three deadly puzzles / traps that only someone smart enough to be in their guild could solve. Lotsa goodies were stored in the tower too.
So anyway, the PCs got past the puzzle on the first and second floors (they were shocked at how dangerous the traps were, because I'm normally not such a vicious DM, though they hadn't suffered any casualties). On the second floor they noticed a strange room with long chutes in the ceiling, and some scraps of flesh and metal on the ground.
The third and last puzzle was in a large room, one entrance and one exit, with a computer terminal in the center. The terminal had five buttons--a small triangle, a medium-sized triangle, a large triangle, a square, and a pentagon--and the message "Sum of the hours in the day". The PCs pressed some button at random, having no idea what was up with the terminal, when suddenly adamantine portculises fell over the doorways and there heard a grinding sound and felt a breeze suddenly kick up in the room. The floor began receeding towards the center of the room, forming a large platform (still enough room for everyone to stand). They noticed that off the platform were a series of spinning bladed fans. Falling off the platform would be certain doom.
Realizing how high the ante had been raised, the party tried to decipher the message. Try as the could, though, they couldn't figure it out. I gave a few hints, like "think polyhedrons". So they tried again, and the platform shrank again. The footing was getting bad, and with another wrong answer someone would probably fall off.
Having no confidence in their abilities, the party made some plan where one of the character's flying axe (long story again, basically made a pact with a demon to get it) would support most of the party in the air. Some would hang on to the ax, another (a warforged they met inside the tower who was following them around) would sit inside a large bag of holding to reduce its weight. One of them would fire a strange artilery weapon they found at the fans in an attempt to destroy them. So with this ready, they made a final, desparate guess.
And it was wrong. The platform shunk even more so only one person could stand on it. The others hanged picariously in the air, made more difficult by the winds that threatened to pull them down. So one of the PCs flipped out and began pressing buttons at random. The computer quickly deactivated, the platform disappeared, and the fans spun even faster.
While none of the PCs fell, they knew that they would soon. So one decided to fire the mysterious cannon at the fans. At this point I think its worth mentioning that they had no idea what the cannon did, and they found it in a lab with many other cursed items. Anyway, he pulls the trigger and it shoots out a huge gout of water with enough recoil that he flies back and knocks several people off the flying ax. One of the PCs was killed by the blades and the fall, another (a greenbond kid named Charlie) was literally chopped to pieces, though somehow he stabilized at around -7.
In desparation, the PC with the axe lowered the warforged (who was actually sitting in the mouth of a bag of devouring) near the fan blades. The warforeged hit the fan with a greatax rolling a natural 20. The bent the fan enough so that maybe, just maybe, the survivors could slip though.
The warforged went first, and chunks of metal and stone fell among the other two PCs. The other two players get lucky and slipped though, taking a hefty amount of damage but still in one piece.
They fell through the pit below the fan blades and into the room on the second floor, the one with bits of broken metal and flesh. Now it was bathed in gore. They checked on Charlie and were amazed he survived . . . though he lost a leg, a hand, some fingers, and sustained horrific body wounds (I was using Torn Asunder at the time). They healed the poor tramautized child as best they could and said a prayer for their other fallen companion.
Anyway, at about that point the session was over. The puzzle had taken at least 3 hours of game time. I told the party the solution: the different shapes corrospond to dice (large triangle = 4, medium tri = 8, small tri = 20, square = 6, pentagon = 12). While I thought this was really clever, they were quite annoyed it required a metagame solution. Later, the PCs were able to get through the trap the second time (they knew the solution) and got the juicy treasure on the top floor.
Despite how horrible this all sounds, the players found their plight to be hilarious. It was one of the most enjoyable and memorable sessions I DMed . . . though I certainly wouldn't do the same thing over again. Charile, who had many more traumatizing experinces (including getting trample by a stampede of giant, but harmless, centipedes deep below the earth) eventually used a magic ritual that restored his lost limbs with ones made of stone.