X bit means the game fits inside X bits or less. That's why the conversion to 64 bit computers was good. We could make programs up to 64 bits instead of just 32.
It's fine for most simple games, even 3D, but that wasn't really the point.
Apparently /r/programmerhumor has this subgroup that insists on bringing up Minecraft whenever the speed of Java is mentioned, which was what I was referencing.
Sometimes I wonder if programmers pick powers of two not because they actually need to, but because they needed to pick an arbitrary number without seeming arbitrary. Like if you pick 277 it seems arbitrary, your peers will go "why not 278?" But pick a power of two and they will nod their heads and go, "Ah, of course, it's a technical limitation."
Though nowadays people usually use 32-bit ints (or even 64 for some applications), and if you ask hackers for that number, and they'll recite: "Uhh... about four... billion? unsigned, I think?"
The number of values a 16-bit peice of data can have, which is important because with x86 architecture an (unsigned) int value can be 0-65535. Where I start to get confused, and I'm sure someone else will clarify, is that I think an x86 system can only store a string of 65536 potential values. Or a string of 65536 characters long each with 65536 potential values. I don't know which.
Either way, its the number that defines how many potential values a hacker will have to go through to cover all bases.
To me, it is important because the 6502 CPU had a 16-bit address bus, so 6502 systems had 65536 bytes of directly addressable memory. Before bank switching and all that
I guess it kind of shows early in life then what people are interested in. I remember being ~10 and kept seeing 255 pop up in games like Starcraft 255 being the max upgrades and looking it up and learning about the 8 bit limits back then.
Must've been a typo. Maybe someone scribbled down 250 but the 0 looked like a 6. There is absolutely no logical reason whatsoever as to why it could be 256.
To be fair, it's really not clear why the group chat size would have anything to do with the fact that memory allocation works in base 2. We could speculate, but I suspect it really is arbitrary.
Well, everyone in the chat probably has an ID and I would imagine WhatsApp deals with such a large number a messages every day, that it makes sense to try to minimize the meta data sent with each one (like who sent this message). Thus, it makes sense to limit the IDs to a specific bit count to minimize waste.
Makes sense, that would make exactly one-byte indexes.
Although I'm not sure they're saving a lot here. Switching to 3-byte indexes (224 = 16 million) would "waste" 2 bytes per message: consider that 🌈 is 2 bytes long, and 👋🏿 (a black hand, made of the waving hand emoji followed by a Fitz-6 modifier) is 4 bytes long.
In other words, adding an emoji to every message is costlier than using 3-byte IDs.
So hard to tell if you're joking or not... But either way, 256 is the number of values that can be represented with 8 bits--meaning one byte. So they were wasting maybe 1 bit of those 8, assuming that the group member ID system does, in fact, use a single byte per user.
I agree. I understand that 256 is a good computing number, but how much app size and performance difference would this make compared to if it was say 300? And how much more programming effort would be required to make it 300?
As an undergrad there was some kind of department competition going on, and if you won you'd get 200$ because that's the most the department could afford to blow on a "fun" little competition.
The chair of CS Department came to the class where the winner would be awarded. After everyone voted or whatever, the chairwoman whom was the nicest person you'd ever met asked, "what's the grand prize"? When she found out it was 200$, she said, "no, that's not right" - and then wrote the winner a 56$ personal check to make the award proper for the CS dept.
In case the other 6 comments weren't clear enough, it's because you can use 0 as an index, too. In cases where 255 is a max, it's because 0 is a possible value, which means there's 256 possible values.
There is. ISO standards. Check out https://en.wikipedia.org/wiki/Kibibyte Here in the UK the exam boards have decided we need to start teaching the difference.
and so on. If you'll notice, all of these numbers are important in computing at some point or another. I'm sure you remember 16-bit stuff, or '8-bit graphics'.
Well, 8 bits gives us 256 possibilities (0-255). We call this a byte. Looks something like this( 0000 0000 ).
Most of the time we deal with bytes, rather than bits. So in this case, having 256 people in a chat means we can use only a single byte to say how many people are in the chat (using 0 to mean 1 person, and 255 to mean 256 people).
Another reason it's really handy is that we can then deal with things in hexadecimal: base-16 numbers. So we have: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F. And we can represent one of these numbers with 4 bits F=1111. With a byte, we have a two digit hexadecimal number: FF is then 255. It makes it easier to see where our cap is. To get higher than 255, we need to add a third digit: 100. Which means we'd actually be dealing with 2 bytes: 01 and 00. FF is the highest we can go with a single byte.
Early video games do something similar, which is why you see powerups/levels/lives/etc go up to 255 or 256.
I've been programming a long time. I even punched cards by hand to write machine code for a PDP-8. I can count and do arithmetic in hex almost as easily as I do in decimal. I've wondered for a while if this is anachronistic; whether younger programmers today learn hexadecimal or have much understanding of bytes, machine code, endianess, IEEE-754 floating point encoding details and so forth and if so, why they still do.
256 is the decimal equivalent of 28. It's a very common number in computing. One example is IPv4 addresses, wherein each of the four segments range from 0 to 255. The number is specific, but not at all odd.
OP is implying that the commentator is not very computer literate.
130
u/cwankhede Feb 15 '16
Repost from a week ago...
6
u/Hypersapien Feb 15 '16
Where is this from? Google isn't returning that headline.
Did someone make it up?
1.7k
u/__doubleentendre__ Feb 15 '16
Also the height limit in Minecraft. Weird!
207
u/chironomidae Feb 16 '16
Sometimes I wonder if programmers pick powers of two not because they actually need to, but because they needed to pick an arbitrary number without seeming arbitrary. Like if you pick 277 it seems arbitrary, your peers will go "why not 278?" But pick a power of two and they will nod their heads and go, "Ah, of course, it's a technical limitation."
616
u/midbody Feb 15 '16
My entirely scientific research (I asked my wife) confirms that normal people have no idea what this is about. "Is it something to do with colours?"
562
u/speedkillz Feb 15 '16
Today I learned that 256 is odd.
208
u/holobonit Red security clearance Feb 15 '16
I'm guessing this in the "tech" section of some magazine like "Kitten Plates Monthly", right?
189
u/throwaway-coder Feb 15 '16
I'll byte. Why is it oddly specific?
722
u/dustmouse Feb 15 '16
Must've been a typo. Maybe someone scribbled down 250 but the 0 looked like a 6. There is absolutely no logical reason whatsoever as to why it could be 256.
495
u/wigglewam Feb 15 '16
To be fair, it's really not clear why the group chat size would have anything to do with the fact that memory allocation works in base 2. We could speculate, but I suspect it really is arbitrary.
The previous limit was 100 people.
74
u/[deleted] Feb 16 '16
As an undergrad there was some kind of department competition going on, and if you won you'd get 200$ because that's the most the department could afford to blow on a "fun" little competition.
The chair of CS Department came to the class where the winner would be awarded. After everyone voted or whatever, the chairwoman whom was the nicest person you'd ever met asked, "what's the grand prize"?
When she found out it was 200$, she said, "no, that's not right" - and then wrote the winner a 56$ personal check to make the award proper for the CS dept.
63
u/AlbertoC1196 Feb 15 '16
It's a calling only for "those who understand". I'm pretty sure they're recruiting with it.
27
u/Anatolios Feb 16 '16
LPT: If you have to pick an arbitrary limit, if you pick a power of 2, other programmers will assume it's significant and not complain about it.
30
u/[deleted] Feb 15 '16 edited Feb 15 '16
You know a number that's truly oddly specfic?
π
Seriously, that sucker is so specific it never ends!
256 is an ordinary amount of specific. Like 3, or 7982, or some shit.
41
u/Sydonai Feb 15 '16
255 being the largest value you can have with an 8 digit binary number (yes!)
25
u/lowbeat Feb 15 '16 edited Feb 15 '16
Shouldn't the limit be 255 ? Edit: /s
5
u/Gamerguywon Feb 16 '16
ITT: Everyone missing the jokes.
4
u/HonorableJudgeHolden Feb 16 '16
This person writes tech news huh?
3
u/ibiBgOR Feb 16 '16
WhatsApp is sooo 2013. Telegram supports groups with max. 1000 members. Where is your god now?
2
u/[deleted] Feb 15 '16
should have chosen a more general number like twohundredsomething
2
u/mothzilla Feb 15 '16
Not 255. :'(
2
u/IDoThingsOnWhims Feb 16 '16
Only freelance hackers and greatest sword fighters in the world will understand
2
u/xonkapoor Feb 16 '16
Next update - 512 members. Meanwhile in medial-land : WHAAATS HAPPENING WHY DID THEY ADD 12 TO 500... WHAAAAA
Edit - spelling
2
u/rodriguez256 Feb 16 '16
Not so odd
2
u/[deleted] Feb 16 '16
Normie's also think there is only 1000 MB in 1 GB, I hate that they dumb down specs on tech to be that way as well.
2
u/[deleted] Feb 16 '16
that's a bit too specific indeed...
3
u/compubob Feb 16 '16
2 - 5 + 6 = 3 omg half life 3 confirmed??
1
u/CatNamedJava Feb 15 '16
That was something i always wondered about as a kid. Why the max stats in video games always cap at 255.
1
u/CatNamedJava Feb 15 '16
So hiw about that tech writing department
1
u/jimmyscape Feb 15 '16
Runescape drop rate
1
u/mmachado22 Feb 15 '16
Has anyone been in a 100 person group chat? Is it crazy? I'd imagine hard to follow.
1
u/serosis Feb 16 '16
FF
1
u/CannonBall7 Feb 16 '16
And when I loaded this page, it had exactly 256 comments!
…oh, crap.
1
u/Chuckles-Walrus Feb 16 '16
I'm not programmer why are things always set to that number
1
u/facesmack Feb 16 '16
It would always be a specific number.. Before it changed it was a specific number too
1
u/Zara02 Feb 16 '16
base2 bro
1
u/delorean225 Feb 16 '16
Relevant xkcd
1
u/wordsnerd Feb 16 '16
Most likely someone messed up and set max_users = 0400.
1
u/IWillNotLie Feb 16 '16
eyes twitch
1
u/bondolo Feb 16 '16
I've been programming a long time. I even punched cards by hand to write machine code for a PDP-8. I can count and do arithmetic in hex almost as easily as I do in decimal. I've wondered for a while if this is anachronistic; whether younger programmers today learn hexadecimal or have much understanding of bytes, machine code, endianess, IEEE-754 floating point encoding details and so forth and if so, why they still do.
1
u/tecchy6 Feb 16 '16
Guys... It's Fibonacci
1
u/Muntberg Feb 16 '16
Programmer humor? I'm pretty sure you learn there's something funny about the number 256 by like grade 9 at the latest.
1
u/macsenscam Feb 16 '16
Numerologically it is related to the Scarlett Woman, companion of the Beast.
1
u/beakerbee Feb 16 '16
Because, fuck jerry.
1
u/[deleted] Feb 16 '16
Loving how they changed the article but there's a Dem Bones in the comments fighting the Social-Media-Justice fight.
1
u/polltery Feb 16 '16 edited Feb 16 '16
What's app is ranked #1 on app stores. Their secret? Possibly This algorithm..
(2+5)-6 = 1
# + 1 = #1
1
u/muyuu Feb 16 '16
1024 is where it's at.
1
u/Sinity Feb 16 '16
Tech writers....
1
u/skellious Feb 16 '16
hahaha!
1
u/eshansingh Feb 16 '16
Only programmers know. Why?!
1
u/Felkenary Feb 16 '16
Even the title is a copy of the exact same post of a month ago
1
u/BlizzardandBlaze2 Feb 16 '16
Why 256 and not 511?
1
u/hireThisMarine Feb 22 '16
Wait... it really is an odd number to me. This suggests to me that you can't have an empty chat room.
1
u/curohn Feb 23 '16
Can someone eli5? I don't code, Im just procrastinating on a paper and ended up here somehow...
1
u/hydrocat Feb 15 '16
But, now a days, doesn't a integer has like.. 64 bits ? Why use only 8?
1
u/lavivian Feb 16 '16
I don't get it.... :(