@[email protected] to Microblog [email protected]English • 22 days agooddly specificlemmy.blahaj.zoneimagemessage-square199fedilinkarrow-up11.49K
arrow-up11.49Kimageoddly specificlemmy.blahaj.zone@[email protected] to Microblog [email protected]English • 22 days agomessage-square199fedilink
minus-squareZagorathlinkfedilinkEnglish1•21 days agoI’m imagining something like this: def add_member(group, user): if (len(group.members) <= GROUP_CHAT_LIMIT): ... If GROUP_CHAT_LIMIT is 8 bits, this does not work.
minus-square@[email protected]linkfedilinkEnglish4•21 days agoSo add a +1 like you would for any index to count comparison? I guess I’m failing to see how this doesn’t work as long as you properly handle the comparison logic. Maybe you can explain how this doesn’t work…
I’m imagining something like this:
If
GROUP_CHAT_LIMIT
is 8 bits, this does not work.So add a +1 like you would for any index to count comparison?
I guess I’m failing to see how this doesn’t work as long as you properly handle the comparison logic. Maybe you can explain how this doesn’t work…