Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Variables
Romulator Offline
Not Tech Support ;-)

Posts: 3,628
Threads: 63
Joined: Jan 2013
Reputation: 195
#7
RE: Variables

(09-15-2014, 11:46 AM)FlawlessHappiness Wrote: Thank you guys ^^
Great clarifications!


I still didn't get an answer to what a double is...

In short:
A big float number of an extremely large range, consisting of 64-bit allowance of digits.

In long:
Spoiler below!

[Image: JavaBasics_ImplicitTypeCastingPrimitives.png]

A Double is a float, which consists of 64-bit sizing. What that gibberish means is that it can handle a greater range than, for example, a float.

A float, as we know, is a number which allows decimal point usage. The range of a float is between -9,223,372,036,854,775,808 to 9,223,372,036,854,775,808 (including 0). To calculate this, we use (2^x)/2, where x is the suitable data type size in bytes. We divide by two to get the maximum and minimum, as floats allow negative and positive numbers. Without dividing by two, we get the count - that is, 1.8446744e+19 possible numbers.

A double is pretty much the same thing, except it is 2^64 numbers. I cannot calculate that, nor can google, but it is a pretty large range which accepts some pretty big numbers. However, apparently it is 4.94065645841246544e-324d to 1.79769313486231570e+308d digits long as a positive and negative range.


Discord: Romulator#0001
[Image: 3f6f01a904.png]
(This post was last modified: 09-15-2014, 12:23 PM by Romulator.)
09-15-2014, 12:21 PM
Find


Messages In This Thread
Variables - by FlawlessHappiness - 09-14-2014, 10:25 PM
RE: Variables - by Mudbill - 09-15-2014, 12:17 AM
RE: Variables - by FlawlessHappiness - 09-15-2014, 12:25 AM
RE: Variables - by Mudbill - 09-15-2014, 07:32 AM
RE: Variables - by Romulator - 09-15-2014, 08:16 AM
RE: Variables - by FlawlessHappiness - 09-15-2014, 11:46 AM
RE: Variables - by Romulator - 09-15-2014, 12:21 PM
RE: Variables - by FlawlessHappiness - 09-15-2014, 12:47 PM



Users browsing this thread: 1 Guest(s)