$color = "Green";
print "$color apple.\n";
You would want:
color = "Green"
print "%s apple." % color
Both of which would print "Green apple." That is actually something I like about Perl, but it reinforces some bad habits, at least for me. Boilerplate coding, as it were, when doing quick and dirty web stuff, which always ends up growing! That and inline regex will probably be the hardest thing to get used to.
Good luck with Python, but you really won't need it. I wrote a script in Perl today to show a friend how to do something, and it reinforced the amazing amount of -stuff- you need to remember to use Perl, and the mind-draining way you can't type without thinking about which way you will type it. I swear it scares people away from other languages for life :)
Python will be much, much easier to learn. And hopefully you'll spend more time typing what you want, than deciding how you should type it, while doing the exact same things you always did.
On 10/5/05, Eric Walker <[EMAIL PROTECTED]> wrote:
Thanks Kent.. I think that would work for what I am doing. So is it safe to
say that python doesn't do variable interpolation like perl..?
Thanks in advance.
Python Newbie...
_______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor