485
oddly specific (lemmy.blahaj.zone)
top 50 comments
sorted by: hot top controversial new old
[-] MentalEdge@sopuli.xyz 61 points 1 week ago

If it's engagement bait, it's working.

[-] ignoble_stigmas@sh.itjust.works 12 points 1 week ago

Engagement byte

[-] MyBrainHurts@lemmy.ca 3 points 1 week ago

So far at least, I've found this much more charming than culture war bait.

[-] Cris_Color@lemmy.world 3 points 1 week ago

I wish we could see what outlet it was for context

load more comments (1 replies)
[-] Chozo@fedia.io 59 points 1 week ago

Source.

This isn't a "tech article", it's an article about tech. This is a normie article from a normie news outlet for normie readers.

Also from the article:

A previous version of this article said it was "not clear why WhatsApp settled on the oddly specific number." A number of readers have since noted that 256 is one of the most important numbers in computing, since it refers to the number of variations that can be represented by eight switches that have two positions - eight bits, or a byte. This has now been changed. Thanks for the tweets. DB

[-] wuzzlewoggle@feddit.org 12 points 1 week ago

One of the most important numbers? I'd argue the most important number in computing is either 1 or 0...

[-] jaybone@lemmy.zip 13 points 1 week ago

What the fuck is a power of 2??? I’m vibe coding python AI.

load more comments (2 replies)
load more comments (2 replies)
[-] markz@suppo.fi 11 points 1 week ago

That weird ass explanation with switches and "one of the most important numbers" still sounds absolutely clueless.

load more comments (2 replies)
load more comments (6 replies)
[-] xeekei@lemmy.zip 32 points 1 week ago

You know you're a tech nerd when 256 sounds more even than 250 or 300. 😅

[-] Saleh@feddit.org 10 points 1 week ago* (last edited 1 week ago)

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.

load more comments (3 replies)
[-] silasmariner@programming.dev 9 points 1 week ago

Or a maths nerd!

load more comments (5 replies)
[-] spongebue@lemmy.world 27 points 1 week ago

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.

[-] Zagorath@aussie.zone 6 points 1 week ago

Except that they're almost certainly just using int, which is almost certainly at least 32 bits.

256 is chosen because the people writing the code are programmers. And just like regular people like multiples of 10, programmers like powers of 2. They feel like nice round numbers.

[-] Lodespawn@aussie.zone 18 points 1 week ago

It'll have to do with packet headers, 8 bits is a lot for an instant message packet header.

[-] verstra@programming.dev 16 points 1 week ago

Well, no. They are not certainly using int, they might be using a more efficient data type.

This might be for legacy reasons or it might be intentional because it might actually matter a lot. If I make up an example, chat_participant_id is definitely stored with each message and probably also in some index, so you can search the messages. Multiply this over all chats on WhatsApp, even the ones with only two people in, and the difference between u8 and u16 might matter a lot.

But I understand how a TypeScript or Java dev could think that the difference between 1 and 4 bytes is negligible.

[-] MyBrainHurts@lemmy.ca 17 points 1 week ago

But I understand how a TypeScript or Java dev could think that the difference between 1 and 4 bytes is negligible.

Shots fired.

load more comments (2 replies)
load more comments (5 replies)
load more comments (1 replies)
[-] spongebue@lemmy.world 3 points 1 week ago

If each user is assigned a number as to where they're placed in the group, I guess. But what happens when people are added and removed? If #145 leaves a full group, does #146 and beyond get decremented to make room for the new #256? (or #255 if zero-indexed). It just doesn't seem like something you'd actually see in code not designed by a first semester CS student.

Also, more importantly, memory is cheap AF now 🤷‍♂️

[-] SandmanXC@lemmy.world 29 points 1 week ago

While I completely agree with the sentiment, snorting too much "memory is cheap AF" could lead to terminal cases of Electron.

[-] morphballganon@lemmynsfw.com 5 points 1 week ago

There would be no need to decrement later people because they're definitely referred to using pointers. You'd just need to update the previous person's pointer to the new next person.

[-] mEEGal@lemmy.world 10 points 1 week ago

when writing somewhat low-level code, you always make assumptions about things. in this case, they chose to manage 256 entries in some array; the bound used to be lower.

but implicitly there's a tradeoff, probably memory / CPU utilisation in the server.

it's always about the tradeoff between what the users want, what is easier for you to maintain, what your infrastructure can provide, etc.

[-] SparroHawc@lemmy.zip 7 points 1 week ago

There's often a lot of fun cheats you can use - bitwise operators, etc - if your numbers are small powers of two.

Also it's easier to organize memory, if you're doing funky memory management tricks, if the memory you're allocating fits nicely into the blocks available to you which are always in powers of two.

They're not necessarily great reasons if you're using a language with sufficient abstraction, but it's still easier in most instances to use powers of two anyways if you're getting into the guts of things.

[-] hemko@lemmy.dbzer0.com 3 points 1 week ago

Maybe each user has a user id in a group, and that group user id is stored as 8bit int? Idk

[-] vala@lemmy.world 20 points 1 week ago

ITT: People who have never done low level networking.

[-] jsomae@lemmy.ml 16 points 1 week ago

Shout out to Castlevania II, where you can hold anywhere from 0 to 256 laurels. Yes, you read that right -- 256, not 255. I inspected RAM to double check. It's a 16-bit word on an 8-bit system with a maximum value of 0x100. They could have used 8 bits instead of 16. But no, they really did choose this arbitrary number.

[-] AnarchistArtificer@slrpnk.net 13 points 1 week ago

"I inspected RAM to double check."

That's an unhinged level of commitment. Respect — I dig it

[-] JackbyDev@programming.dev 5 points 1 week ago

I hate this. I love this.

If I ever make a game I might put stuff like this in it.

load more comments (8 replies)
[-] rarbg@lemmy.zip 13 points 1 week ago

A previous version of this article said it was "not clear why WhatsApp settled on the oddly specific number." A number of readers have since noted that 256 is one of the most important numbers in computing, since it refers to the number of variations that can be represented by eight switches that have two positions - eight bits, or a byte.

Lol, weird way to say that 256 is a power of two, and computers operate in base two.

[-] JackbyDev@programming.dev 6 points 1 week ago

It's a pretty succinct explanation that links what it is to something most people have heard of (a byte).

load more comments (2 replies)
[-] prime_number_314159@lemmy.world 12 points 1 week ago

Numbers guy here, I can confirm 256 is an evenly specific number, and not an oddly specific number.

load more comments (18 replies)
[-] BilboBargains@lemmy.world 8 points 1 week ago

I remember being puzzled by this and many other numbers that kept cropping up. 32, 64, 128, 256, 1024, 2048... Why do programmers and electronic engineers hate round numbers? The other set of numbers that was mysterious was timber and sheet materials. They cut them to 1220 x 2440mm and thicknesses of 18 and 25mm. Are programmers and the timber merchants part of some diabolical conspiracy?

[-] JackbyDev@programming.dev 9 points 1 week ago

Powers of two are the roundest of numbers.

load more comments (1 replies)
[-] Worx@lemmynsfw.com 7 points 1 week ago

32, 64, 128 etc. are all round numbers, counting in binary. They are powers of two. Since computers work in binary, they make logical sense.

1220mm is 4ft, and 18 and 25mm are three-quarters of an inch, and an inch respectively.

[-] Scubus@sh.itjust.works 9 points 1 week ago

They were making a joke. That being said, im not familiar with lumber or imperial<->metric conversions so their second point was lost on me, so thanks.

load more comments (2 replies)
[-] MilitantAtheist@lemmy.world 5 points 1 week ago

Because 257's a crowd

[-] ch00f@lemmy.world 4 points 1 week ago

I'm typing this on a 64 bit device. Why anyone would limit something to an 8 bit number in 2025 is really odd.

[-] magic_lobster_party@fedia.io 14 points 1 week ago

It’s for their servers. I guess it might have to do with cache optimization reasons. For performance reasons, they want to ensure they can fit as much as possible in the cache. One extra byte can throw the memory alignment off, which cause wasted space in cache.

Just my guess. There might be other reasons.

load more comments (1 replies)
[-] MudMan@fedia.io 11 points 1 week ago

On a device with many gigabytes of RAM and probably terabytes of storage.

I guess when you have billions of users, and presumably tens or hundreds of billions of instances of a thing living in your sever every bit adds up? I don't even know where to even start doing the napkin math for something like that.

load more comments (1 replies)
[-] undefined@lemmy.hogru.ch 7 points 1 week ago

I get what you’re saying but I don’t like this line of thinking. In the tech industry there is far too much bloat that we just accept due to cheap memory and storage.

load more comments (1 replies)
[-] tired_n_bored@lemmy.world 3 points 1 week ago

As a software engineer: actually there is no need for a number of people as a power of 2 unless you need exactly 1 byte to store such information which sounds ridiculous for the size of Whatsapp

load more comments (2 replies)
load more comments
view more: next ›
this post was submitted on 07 Jul 2025
485 points (99.2% liked)

Microblog Memes

8553 readers
1955 users here now

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:

  1. Please put at least one word relevant to the post in the post title.
  2. Be nice.
  3. No advertising, brand promotion or guerilla marketing.
  4. Posters are encouraged to link to the toot or tweet etc in the description of posts.

Related communities:

founded 2 years ago
MODERATORS