@MaliciousKebab@sh.itjust.works to Programmer Humor@programming.devEnglish • edit-211 months agoNeed a rust version too.toggl.comimagemessage-square92fedilinkarrow-up1857
arrow-up1857imageNeed a rust version too.toggl.com@MaliciousKebab@sh.itjust.works to Programmer Humor@programming.devEnglish • edit-211 months agomessage-square92fedilink
minus-square@bob_lemon@feddit.delinkfedilink25•11 months agomap(lambda princess: princess.rescue(), [castle.get_princess() for castle in castles])
minus-square@scratchresistor@thelemmy.clublinkfedilink6•11 months agoDon’t forget to keep your return values… rescued_princesses = [{"princess": princess, "rescued": princess.rescue()} for princess in [castle.get_princess() for castle in castles]]
map(lambda princess: princess.rescue(), [castle.get_princess() for castle in castles])
Don’t forget to keep your return values…
rescued_princesses = [{"princess": princess, "rescued": princess.rescue()} for princess in [castle.get_princess() for castle in castles]]