[Tutor] what is foo bar?

Dennis E. Hamilton infonuovo@email.com
Mon, 27 Mar 2000 11:18:11 -0800


Great question!

I can't remember when I first saw foo and bar used in examples.  It was a
long time ago.  I have this sense that it was quite popular around MIT and
maybe even the DEC crowd and in the Multics community.  It is typically used
in composing file names in code examples about file processing.  There is
also a potential pun, from the days when connections to files had funny
names, like A01, C05, F00 (those are zeroes).

It is a mild joke.  There is an old US military acronym, FUBAR (other
military organizations will have their own versions).  In the context of
Python it means something like "Friendlied Up Beyond All Recognition".  Cf.
RTFM.  Once you've seen it, it becomes difficult not to use it.  The
continued use of it is for the same reason that it was used in the first
place:  "Where can I get some easy, meaningless file names to use in an
example?"  It's easier than inventing new names.  And it is automatic.  And
there is tacit knowledge of it in the community, like recognizing a recuring
character in your favorite series of novels.

I'd be amazed if FOO and BAR are *not* mentioned in the Hackers Dictionary.

I'm grateful that you asked.  It reminds us of how much is taken for granted
that, for a neophyte, is not easily distinguished as having material or only
incidental importance.   With the wonderful international nature of
computing today, it is an important challenge for those of us who are
already "in the know" to provide clarity and simplicity.

-- Dennis

------------------
Dennis E. Hamilton
InfoNuovo
mailto:infonuovo@email.com
tel. +1-206-779-9430 (gsm)
fax. +1-425-793-0283
http://www.infonuovo.com

-----Original Message-----
From: tutor-admin@python.org [mailto:tutor-admin@python.org]On Behalf Of
Walter Hanagriff
Sent: Sunday, March 26, 2000 22:21
To: tutor@python.org; tutor@python.org
Subject: [Tutor] what is foo bar?


greetings to all yet again:

the words foo and bar are used so much in examples, why?
there is even this example: 'from foo import *'
does this do something, i got it from an example of
importing a package, and the comment on it
was that it was poor style, does foo and bar, or just foo or
bar actually do something
or just useful as example names of variables, modules and
such?

______________________________________________________
Get your free web-based email at http://www.xoom.com
Birthday? Anniversary? Send FREE animated greeting
cards for any occasion at http://greetings.xoom.com



_______________________________________________
Tutor maillist  -  Tutor@python.org
http://www.python.org/mailman/listinfo/tutor