Sure, you may learn how to do a for loop or how variables work. But, you don't learn how to actually use the language. Setting up a development environment, and understanding how everything is connected is much more important.
Let's say you ace everything here, on CodeAcademy, etc. You still can't actually build anything.
this kind of thing is a good resource for people who already know how to code, but need a fast and elegant syntax guide. its not useful for teaching beginners because, as you've said, it doesn't deal with the tool chain or project organization, etc. but if you know Ruby and want to learn Python, this is a great resource.
I really don't buy the "you have to own a car to drive one arguments" and the whole point of modern software engineering is to pull you away from the assumption of full system control and the ability to make problems go away with shell skills.
But, I would like more immediate source code management integration. That is the essential reality I always see lacking..
A non-programmer that understood git basics would be more helpful to me as a colleague than a competent programmer that doesn't.
I tend to disagree. It works in a sense that it can take a person with no knowledge of the syntax and flow of a language and remove some of the fear of getting started. I think it is a great non-intimidating way to get an overview of a language. Yes, they are going to need more instruction, but it's a start.
This particular behaviour can occur because the process is disallowed to call fork() and can be done with setrlimit() (see RLIMIT_NPROC). There should be other protections, though, because forking a "ls" is not the only way to access the filesystem.
Execv'ing processes is OK as long as you don't fork:
__import__("os").execv("/usr/bin/uname", ["uname", "-a"])
Linux ip-10-196-3-111 2.6.32-amazon-xen-r3 #1 SMP Mon Jan 16 21:03:16 PST 2012 i686 GNU/Linux
As for the actual files, there are a few clues that a chroot is created for every request : /proc is not mounted, /etc is minimal (root + 1 user in passwd) and "ls -id /" returns a new inode number every time.
adam.py... :) If only I knew more about bytecode...
pp = pprint.PrettyPrinter(depth=6)
f = inspect.currentframe()
c = 0
while f is not None:
c += 1
if c == 20:
f = f.f_back
This is beautiful and the usability is great. But can anyone recommend some online interactive Python learning that starts at the intermediate level? I need Pai Mei to whip my sorry skills into shape, starting with OOP, sockets, image handling, and maybe data persistence?
"A programmer may try to get you to install Python 3 and learn that. You should tell them, 'When all of the python code on your computer is Python 3, then I'll try to learn it.' That should keep them busy for about 10 years."
Python 3, in 2013, is not lacking in pragmatism. It's not new, or experimental. Someone just learning today is going to have to immediately turn around and relearn things because they started out with an old version.
I'm teach Python professionally. People come to learn Python so that they can go back and use it at their work place. And almost all Python installations in productions are in Python 2. I'm sure it is going to change soon once Linux distributions make Python 3 their default version.
P.S. I'm the author of Python Primer on pythonmonk.com
there's nothing experimental about Python 3. its a stable release version and I think its already up to sub version 3.3.
HOWEVER, there are many important 3rd party libraries that have not yet been migrated to be fully compatible with Python 3. these libraries are far more important to writing real applications than the ability to use some newer syntactic constructs in Python 3.
I think this is a great way to get beginners / students coding, but the end product might be what we now know as "bolt-on" engineers.
They put components together and build beautiful functional products, until it breaks and they have no idea what's "under the hood"