Foobar

Source: Wikipedia, the free encyclopedia.
(Redirected from
Foo
)

The terms foobar (

functions, and commands
whose exact identity is unimportant and serve only to demonstrate a concept. The style guide for Google developer documentation recommends against using them as example project names because they are unclear and can cause confusion.[2]

History and etymology

It is possible that foobar is a playful allusion[3] to the World War II-era military slang FUBAR (Fucked Up Beyond All Recognition).[3]

According to an

nonsense word with its earliest documented use in the 1930s comic Smokey Stover by Bill Holman.[4] Holman states that he used the word due to having seen it on the bottom of a jade Chinese figurine in San Francisco Chinatown, purportedly signifying "good luck".[5] If true, this is presumably related to the Chinese word fu ("", sometimes transliterated foo, as in foo dog), which can mean happiness or blessing.[6]

The first known use of the terms in print in a programming context appears in a 1965 edition of MIT's

which?] describing the MIT train room describes two buttons by the door labeled "foo" and "bar". These were general-purpose buttons and were often repurposed for whatever fun idea the MIT hackers had at the time, hence the adoption of foo and bar as general-purpose variable names. An entry in the Abridged Dictionary of the TMRC Language states:[9]

Multiflush: stop-all-trains-button. Next best thing to the red door button. Also called FOO. Displays "FOO" on the clock when used.

Foobar was used as a variable name in the

Jack and the Beanstalk. Intel also used the term foo in their programming documentation in 1978.[10]

Examples in culture

See also

References

  1. ^
    RFC 3092
    - Etymology of "Foo"
  2. ^ "Example domains and names | Google developer documentation style guide". Google for Developers. 2023-06-23. Retrieved 2023-06-26. Ensure that the name is applicable to the user's environment. Don't use unclear terms like foo, bar, and baz.
  3. ^ a b "What does foo mean?". Dictionary.com. Retrieved 2019-08-17.
  4. ^ Eastlake, D; Manros, C; Raymond, E. "Etymology of "Foo"". The Internet Engineering Task Force. Retrieved 2016-04-17.
  5. ^ "The History of Bill Holman". Smokey Stover. 2007-06-13. Retrieved 2019-08-17.
  6. .
  7. ^ Tech Engineering News. Vol. 47. Massachusetts Institute of Technology. 1965. p. 63. Further, it is possible to search for an effective address; e.g., if an instruction such as "add 1 foo" were used, specifying indirect addressing thru location "foo", and location "foo" contained the address of location "foobar", then an effective word search for "foobar" would find location "foo" and the location containing the "add" instruction as well.
  8. ^ "Computer Dictionary Online"., computer-dictionary-online.org
  9. MIT. Archived from the original
    on 2018-01-02. Retrieved 2013-03-12.
  10. Intel Corporation. 1978. Manual Order No. 9800641A. Retrieved 2020-02-29. [1][2]
  11. ^ Mike Ricciuti (2002-07-04). "Microsoft ploy to block Sun exposed". CNET. Retrieved 2019-08-17.

External links

This page is based on the copyrighted Wikipedia article: Foo. Articles is available under the CC BY-SA 3.0 license; additional terms may apply.Privacy Policy