Etymology

Yoda condition

Yo·da con·dit·ion

Today it means: A logical condition with the usual order of operands reversed for various reasons, such as avoiding the accidental misuse of = (assignment) instead of == (equality), an error that is harder to spot when using the normal order of operands. Full definition →

First used early 21st c.
Ask AI about its historyChatGPTClaudePerplexityGoogle AIGrok

The story

An allusion to the somewhat grammatically reversed speech style of Yoda, a character in the Star Wars franchise—for example, "Truly wonderful, the mind of a child is." The term was possibly coined by Félix Cloutier (username “zneak”) in 2010, based on Yoda notation which is claimed to have been coined by Thomas M. Tuerke and published online in 2006.

First known use, by meaning

  • from early 21st c. A logical condition with the usual order of operands reversed for various reasons, such as avoiding the accidental misuse of = (assignment) instead of == (equality), an error that is harder to spot when using the normal order of operands.

Etymology from Wiktionary, CC BY-SA 4.0.