Answer:

No, because double uses 64 bits, the equivalent of about 15 decimal digits of precision.

Unsafe Conversions

In the following situations, the compiler will not automatically perform the conversion.

NO Automatic Conversion
  • Converting from an integer type to another integer type with fewer bits.
  • Converting from a floating point type to another floating point type with fewer bits.
  • Converting from a floating point type to any integer type will possibly lose both precision and magnitude.
  • Conversion to or from boolean is never allowed (not even with a type cast.)

Remember the sizes of the various primitive types (the primitive types char and boolean are not listed here):

typenumber of bits
byte8
short16
int32
long64
float32
double64

QUESTION 8:

Click the button in the appropriate column for the following type conversions. There is only one correct column per row.

conversion No information lost.

Automatic Conversion.
Possible loss of precision.

Automatic Conversion.
Possible great loss of information.

Requires a Type Cast.
byte to short
short to byte
short to long
int to float
float to byte
double to float