kyub@discuss.tchncs.de to Programmer Humor@programming.devEnglish · edit-22 days agoThe infamous "if loop" actually existsdiscuss.tchncs.deimagemessage-square30fedilinkarrow-up1184arrow-down113file-text
arrow-up1171arrow-down1imageThe infamous "if loop" actually existsdiscuss.tchncs.dekyub@discuss.tchncs.de to Programmer Humor@programming.devEnglish · edit-22 days agomessage-square30fedilinkfile-text
minus-squareSaleh@feddit.orglinkfedilinkarrow-up1·edit-25 hours agoCouldn’t you just handle this with: breakflag = False for x in iterator: if breakcondition(x): breakflag = True break dostuff()
Couldn’t you just handle this with:
breakflag = False for x in iterator: if breakcondition(x): breakflag = True break dostuff()