In this case the limit was entirely arbitrary.
The programmers were told to pick a limit and they liked 256. There are issues with having a large number of people in a group, but it wasn't a hardware limit for this particular case.
A place to share screenshots of Microblog posts, whether from Mastodon, tumblr, ~~Twitter~~ X, KBin, Threads or elsewhere.
Created as an evolution of White People Twitter and other tweet-capture subreddits.
Rules:
Related communities:
In this case the limit was entirely arbitrary.
The programmers were told to pick a limit and they liked 256. There are issues with having a large number of people in a group, but it wasn't a hardware limit for this particular case.
But it's still not oddly specific, they picked a nice round number
Still odd, I very much doubt they use a 8bit variable to set this limit. What would this bring ?
Still odd
Actually, it's even.
When the program is running it's probably stored with 32 or 64 bits, but that probably isn't the case for the network packet layout. I can imagine them wanting to optimize network traffic with over 3 billion users even if it's just a small improvement.
Also TIL that Erlang's VM apparently stores strings as linked lists of chars. Very strange.
You know you're a tech nerd when 256 sounds more even than 250 or 300. 😅
It kind of is "more even".
256 is just 2⁸
250 is 2x5³
300 is 2²x3¹x5²
Any division of 256 with an integer and integer result will be even. Most divisions of 250 and 300 with an integer and integer result will be odd.
That's a super old article as well.
They got rightfully roasted in the comments for not knowing even the most basic things about computing.
I remember thinking something similar when I was a kid modding Starcraft. Max levels/ranks in researching was 256 and I always wondered why such a weirdly specific number.
So, I get that 256 is a base 2 number. But we're not running 8-bit servers or whatever here (and yes, I understand that's not what 8-bit generally refers to). Is there some kind of technical limitation I'm not thinking of where 257 would be any more difficult to implement, or really is it just that 256 has a special place in someone's heart because it's a base 2 number?
Because 256 is exactly one byte. If you want to add a 257th member, you need a whole second byte just for that one person. That's a waste of memory, unless you want to go to the 64k barrier of users per chat.
ITT: People who have never done low level networking.
Edit: Without some absolutely crazy hacks, the smallest amount of data you can really transfer or compute on is one byte. 256 requires one byte, 257 requires you to DOUBLE the data used to 2 bytes. Multiply this by whatever data they send and the problem remains the same.
This is the kind of thing that comes up a lot designing custom protocols.
Wouldn't max value for 8 bit (unsigned) integer be 255? Like the number has 256 distinct values, but that includes 0.
If this is about a counter for users in the chat, sure. But if this is an array of users indexed by an 8-bit number, then it will fit 256 slots with the first slot being numbered 0.
You're thinking of the highest integer number, not the "number of numbers" - which is 256, from 0 to 255, and thus 256 possible users in a group chat.