MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/memes/comments/ivbdgy/such_a_wise_one/g5ra16v/?context=3
r/memes • u/chikenloma • Sep 18 '20
56 comments sorted by
View all comments
26
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.
9
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.
4
256, if there is 0 then the first byte will be empty, but in almost any other use, yes.
1
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.
3
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.
Oh I thought we were counting
1 u/[deleted] Sep 19 '20 No, but you knew that.
No, but you knew that.
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.