The other responses about difficult Infocom games are all accurate, but it's worth noting that Hitchhiker's Guide in particular played this as comedy. There were genuinely tough puzzles, but there were also lots of elements which essentially pulled the rug out from under the player to amuse them with unreasonable demands. Broadly, the game didn't feel as fundamentally hard as many of its contemporaries. Instead, it felt like competing against an obstinate and sarcastic opponent, so failing repeatedly was exasperating and funny instead of aggravating.
For instance, lots of early text games required tricky-to-identify commands for technical reasons, like the myriad ways to phrase "use key on door". Mostly, that was just frustrating and accepted because there was nothing better. Hitchhiker's Guide came late enough to parse language somewhat more gracefully, so it replayed that trope as parody by occasionally requiring absurd phrasings for basic commands. "Take aspirin" didn't work, but "get buffered analgesic" (a phrase the game did present to you) did. And then the rest of the time, it went back to fairly normal naming standards so as not to irritate the player.
As a horribly-dated example: Battletoads is infamous as one of the hardest platform games in history, but it was challenging by simply taking the standard play elements of a game like Mario and making them excessively tight and demanding. Syobon Action is also infamously difficult, but its gameplay is (often) relatively forgiving. The challenge comes from suspending normal conventions of games like making threats visible and giving consistent behavior to objects. Putting any one instance of that style in a normal game would be a ridiculous design error, but Syobon is built on escalating that unfairness to the point of humor, and openly demands trial and error as the way to progress.
It's also why the later Infocom game that Douglas Adams collaborated on, Bureaucracy, is one of the best comedies that Infocom released. The subject matter, the obstinacy of parser-driven IF, and increasingly absurd solutions to puzzles all worked hand-in-hand given the subject matter.
+1 - Another great example of difficult games as parody is I Wanna Be The Guy (https://en.wikipedia.org/wiki/I_Wanna_Be_the_Guy). Take all the existing conventions and stereotypes of difficult platform games and exaggerate them to the extreme.
IWBTG is another great example, definitely. And almost the exact same type of classic-NES parody, where Mario:Syobon::Metroid:IWBTG.
Thinking about it a little more, this pattern seems to describe an entire class of games, including non-parodies. Dark Souls is famously hard because of sheer mechanical difficulty, certainly. But it's also rife with learnable, low-threat moments like "when you walk up this staircase, a boulder will fall on you from offscreen". They don't alter the overall difficulty too much, but they clearly convey that the game isn't honoring standard design principles about giving the player a "fair chance". In an odd way, it makes later departures like "the illusory wall doesn't have anything marking its location" feel more justified.
For instance, lots of early text games required tricky-to-identify commands for technical reasons, like the myriad ways to phrase "use key on door". Mostly, that was just frustrating and accepted because there was nothing better. Hitchhiker's Guide came late enough to parse language somewhat more gracefully, so it replayed that trope as parody by occasionally requiring absurd phrasings for basic commands. "Take aspirin" didn't work, but "get buffered analgesic" (a phrase the game did present to you) did. And then the rest of the time, it went back to fairly normal naming standards so as not to irritate the player.
As a horribly-dated example: Battletoads is infamous as one of the hardest platform games in history, but it was challenging by simply taking the standard play elements of a game like Mario and making them excessively tight and demanding. Syobon Action is also infamously difficult, but its gameplay is (often) relatively forgiving. The challenge comes from suspending normal conventions of games like making threats visible and giving consistent behavior to objects. Putting any one instance of that style in a normal game would be a ridiculous design error, but Syobon is built on escalating that unfairness to the point of humor, and openly demands trial and error as the way to progress.