On Sun, Jun 2, 2013 at 9:56 AM, Jim Mooney <cybervigila...@gmail.com> wrote:
> I still sometimes type input instead of that annoying raw_input and get a > weird error. Here's a nifty tip to get around that - and to eliminate one more thing you'd have to change later, if you switch back to 3. Put this near the top of your code (before any calls to input()): try: input = raw_input except NameError: pass Now you can just use input(), and it will have the 3.x behavior in either version. I'll be glad when this all settles out, but Py 3 has been out awhile and an > awful lot seems to only be for 2.7 > I suspect it's going to be like this for a while yet. The differences between 2.x and 3 _seem_ superficial, but some of them are pretty fundamental - so packages that do anything non-trivial really need major rewrites, and then they need to be maintained for both versions. It's sort of analogous to writing a native iOS app, and porting it as a native Android app, and maintaining both. It can be done, but it requires a lot of effort and usually more than a one-man dev team. I saw a quote a long time ago; I'd love to attribute it properly, but...: "God created the world in just seven days. But then, He had no installed base."
_______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor