Someone has recently demonstrated to me that we can print variables in Python like how Perl does.
Instead of:
print(\"%s, %s, %s\" % (foo, bar, baz))
The answer is, no, the syntax for strings in Python does not include variable substitution inthe style of Perl (or Ruby, for that matter). Using … % locals() is about as slick as you are going to get.
… % locals()