Thursday, May 28, 2009

A challenge for youth programmers

I'm officially running a challenge through Digital Open for youth programmers.

Hopefully this is but the first of many Digital Open challenges.

Background:

I've started making my own text-based game in Python executed completely in the Python Shell (a part of IDLE that can be downloaded for free here). What I've discovered is how truly helpful it is to start building bare bones programs before diving into all of the Python modules like Pygame, OpenGL, etc. So, the game really isn't the point at all, but learning to code is.

The Idea:

Build a text based interactive program in Python that is executed only in the Python SHELL. Your game can be something like the old Advent game, or can take a completely different route, its completely up to you.

A Quick Note on Python:

I first got interested in programming when I was maybe 10 or 11, but I spent far too much time worrying about what language to go with. I contacted big-time programmers at large companies, and naturally each one told me to go with whatever language their company was working with. I kept dipping my toe into countless languages, and it took me far too long to learn this:

Python is the most powerful, easy to learn, cross-platform, fun programming language in the world.

Here's what it can do:

-It can create beautifully engineered games like EVE.

-It can work with all forms of math.

-It is by far the best way to network (servers, email parsing, etc.) that I know of.

-It can even work really well with wild things like encryption and codes (a while ago I build a simple encryption program that works with text-files).

-It can even be run off of hardware like microcontrollers, though because of the required interpreter it needs a relatively large one.

-And it can do just about anything else that could ever be done on a computer.

The only thing I know if that it can't do is build an operating system because of the interpreter, but that's fine because there are already lots of really great OSs out there, and to create your own would be unnecessary.

Also:

-Python is very popular, meaning it'll give you job opportunities in the future (NASA uses it, along with many others. In fact, MIT uses it a lot as well. Great thing for your college app, if you think of that kind of thing). This also means that there is a HUGE support group to help you out if you need at hand (there are awesome forums out there to help you like python-forum.org).

-Python is simple and elegant. Don't get me wrong, it's not insanely easy like Scratch (nothing against Scratch, I used to use it every day), but it is not a huge pain to learn like C and C++. The cool thing is that you can achieve in maybe 3 lines of Python code what would take perhaps 30 lines of C++ code just as easily, meaning you can spend more time building your program rather than typing away at endless lines of code like a C++ zombie.

-Python works pretty much everywhere. This is subject to change if you're using a very specific module, but 99.9% of the time your code can be run on Windows, Mac, Linux, and many others.

Start and stick with Python, its awesome.

The Rules:

-The game must be built in Python and executed on in the SHELL.

-You have to write the code all by yourself. No copy/pasting!

-You must be a Digital Open member (17 & under), sign up is free and safe.

Resources:

There are tons of books out there on Python, but if you don't feel like spending loads of money on 1,000 page books, then here are some great free resources I've used.

-Snake Wrangling for Kids is a free ebook in .pdf format on Python programming for kids.

-A Byte of Python is one of my favorites, and is also a free pdf.

-python.org has great overall info on the language.

-python-fourm.org is a great place to look for help.

End of challenge:

TBD.

Prize:

I personally cannot supply a prize, so if there is one then its up to Digital Open. :)

Submission:

Submit a project at Digital Open and tag it with: "Challenge: Text-based Python game".



Good luck!

0 comments:

blogger templates 3 columns | Make Money Online