Python Shorthand (was Re: Why a class when there will only be one instance?

Andrew Koenig ark at acm.org
Wed May 26 14:00:29 EDT 2004


"Ville Vainio" <ville at spammers.com> wrote in message
news:du7fz9ni0ny.fsf_-_ at amadeus.cc.tut.fi...

> Prefixing names with symbols like $ and @ is a great idea - it makes
> the "nouns" (variables) stand out from "verbs", and makes the code
> flow like a natural language, making reading it easy and writing it
> fun!

Interesting idea.  Let's try it with English, using @ for nouns and $ for
verbs:

$Prefixing @names with @symbols like $ and @ $is a great @idea - it $makes
the "@nouns" (@variables) $stand out from "@verbs" and $makes the @code
$flow like natural @language, $making $reading it easy and $writing it fun!

See how much easier the modified text is to read?  :-)





More information about the Python-list mailing list