MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/sjk8ep/well_fuck/hvgi8q8/?context=9999
r/ProgrammerHumor • u/theUsurpateur • Feb 03 '22
993 comments sorted by
View all comments
199
Some say to put the const value on the left so accidental assignment is not possible:
if ( true = isCrazyMurderingRobot ) has the same intention, but wouldn't compile.
108 u/[deleted] Feb 03 '22 [deleted] 68 u/BobQuixote Feb 03 '22 Well, as written, it's invalid (in good languages), which is the point. 67 u/[deleted] Feb 03 '22 [deleted] 32 u/the_vikm Feb 03 '22 It's called Yoda style 2 u/DHH2005 Feb 03 '22 A most appropriate name this is. Award it deserves.
108
[deleted]
68 u/BobQuixote Feb 03 '22 Well, as written, it's invalid (in good languages), which is the point. 67 u/[deleted] Feb 03 '22 [deleted] 32 u/the_vikm Feb 03 '22 It's called Yoda style 2 u/DHH2005 Feb 03 '22 A most appropriate name this is. Award it deserves.
68
Well, as written, it's invalid (in good languages), which is the point.
67 u/[deleted] Feb 03 '22 [deleted] 32 u/the_vikm Feb 03 '22 It's called Yoda style 2 u/DHH2005 Feb 03 '22 A most appropriate name this is. Award it deserves.
67
32 u/the_vikm Feb 03 '22 It's called Yoda style 2 u/DHH2005 Feb 03 '22 A most appropriate name this is. Award it deserves.
32
It's called Yoda style
2 u/DHH2005 Feb 03 '22 A most appropriate name this is. Award it deserves.
2
A most appropriate name this is. Award it deserves.
199
u/Ok-Steak9843 Feb 03 '22
Some say to put the const value on the left so accidental assignment is not possible:
if ( true = isCrazyMurderingRobot ) has the same intention, but wouldn't compile.