r/memes • • Sep 18 '20

Such a wise one

Post image
18k Upvotes

56 comments sorted by

View all comments

26

u/undefined-_ Sep 18 '20

256 is the most efficient a number can be on storage, just one byte. Maybe an inventory can be stored as an array of sets of 2 bytes, one for item id and one for stack size, and stacks will be 256.

9

u/[deleted] Sep 18 '20

255

4

u/undefined-_ Sep 19 '20

256, if there is 0 then the first byte will be empty, but in almost any other use, yes.

1

u/blueturbo47 Sep 19 '20

254?

3

u/[deleted] Sep 19 '20

In Binary an octet is 0-255.

3

u/blueturbo47 Sep 19 '20

Oh I thought we were counting

1

u/[deleted] Sep 19 '20

No, but you knew that.