Alright. I'm teaching myself python from 'Learn Python the Hard Way: 3rd Edition' by Zed Shaw.. it's been informative so far. Definitely learning. After his lessons, he gives study drills, extra project to put your learning to use. He challenged us to: "Find out what Zork and Adventure were. Try to find a copy and play it. (p50)". My approach to this was finding the source code... It's like I can't find the original anywhere. I can find different versions of it or projects made by other, but the original eludes me. I looked at compilr.com and found the source code for Zork.. But I can't tell what this kind of text/language is: "ä½ å头ä¸çï¼èåçéé被ä¸éç³é¨éäºèµ·æ¥ã" ... That was a print string from the source code. but besides the python functions, etc, everything is displayed like that. Is this a failing on my part to understand something python-related or... ? Can I either get an explanation of this or even a link to the source code for this/these game(s)? I've searched across google and duck duck go with no luck.

2 Years
Discussion Span
Last Post by Conrad_2

What you posted does not look like source code, it looks like what you might see when you open a binary file in a text editor. Presumably you downloaded the zcode file (which is a bytecode format), not the source code. I do not think the source code of Zork is publically available at all, which would explain why you were unable to find it.

PS: Neither Zork nor Adventure were written in Python, so even if you did find the source code, it wouldn't be in Python and reading it would probably not help you at all with learning Python.


Thanks sepp2k :) That was helpful. I'll keep going through the book. Am I able to link the page I was looking at here?


A Fortran version of Zork was available in 1975 for the then popular DEC PDP-11 computers. It was later rewritten in C.

I think the author of your book wants you to play the game and to apply the basic concepts to a potential Python game.


Funny, I remember Zork being longer and having a much more sophisticated parser.

In all seriousness though, this is not a good example of how to program a Zork-like game. Not only does it exhibit bad coding practice in general (like using a variable with a completely meaningless name holding magic numbers whose semantics seem completely arbitrary), its whole approach is not suitable to implement a game like this.

I'm sorry if this is your code and this sounds harsh, but no one should take this code as an inspiration to learn how to program.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.