539
Java (lemmy.world)
you are viewing a single comment's thread
view the rest of the comments
[-] EvilHankVenture@lemmy.world 3 points 1 year ago* (last edited 1 year ago)

It doesn't store more values bit for bit, but it can store larger values.

[-] karlthemailman@sh.itjust.works 1 points 1 year ago* (last edited 1 year ago)

I don't think that's possible. Representing more exact ints means representing larger ints and vice versa. I'm ignoring signed vs. unsigned here as in theory both the double and int/long can be signed or unsigned.

Edit: ok, I take this back. I guess you can represent larger values as long as you are ok that they will be estimates. Ie, double of N (for some very large N) will equal double of N + 1.

this post was submitted on 05 Aug 2023
539 points (92.4% liked)

Programmer Humor

19488 readers
191 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS