kyub@discuss.tchncs.de to Programmer Humor@programming.devEnglish · edit-221 days agoThe infamous "if loop" actually existsdiscuss.tchncs.deexternal-linkmessage-square28fedilinkarrow-up11arrow-down10file-text
arrow-up11arrow-down1external-linkThe infamous "if loop" actually existsdiscuss.tchncs.dekyub@discuss.tchncs.de to Programmer Humor@programming.devEnglish · edit-221 days agomessage-square28fedilinkfile-text
minus-squareKacarott@aussie.zonelinkfedilinkarrow-up0·21 days agoBut what is it in reference to? What’s the “infamous if loop”?
minus-squareAliasVortex@lemmy.worldlinkfedilinkEnglisharrow-up0·21 days agoInfamous because the condition is 1 (or true), the loop never actually exits because it’s always true
minus-squareaMockTie@lemmy.worldlinkfedilinkarrow-up0·21 days agoAh, I believe that would be from a college course.
minus-squareNigelFrobisher@aussie.zonelinkfedilinkarrow-up0·20 days agoIt just occurred to that in Yorkshire dialect a while loop would actually be an until loop. Directives to the rescue!
minus-squareulterno@programming.devlinkfedilinkEnglisharrow-up0·20 days agoI always wondered why I always had a hard time making developers not call “if” a “loop”. Turns out it was on their tests. Glad I didn’t read my college material, or I would have lost faith in my college professors.
minus-squarekyub@discuss.tchncs.deOPlinkfedilinkEnglisharrow-up0·20 days ago“Infamous” just refers to newbies who sometimes call if statements “if loops”. I’ve heard this quite a bit.
But what is it in reference to? What’s the “infamous if loop”?
Infamous because the condition is 1 (or true), the loop never actually exits because it’s always true
Ah, I believe that would be
from a college course.
It just occurred to that in Yorkshire dialect a while loop would actually be an until loop. Directives to the rescue!
I always wondered why I always had a hard time making developers not call “if” a “loop”.
Turns out it was on their tests.
Glad I didn’t read my college material, or I would have lost faith in my college professors.
“Infamous” just refers to newbies who sometimes call if statements “if loops”. I’ve heard this quite a bit.