A
A
Alexander Stepanov2020-01-17 21:27:59
Java
Alexander Stepanov, 2020-01-17 21:27:59

What is the difference between int, long and float, double?

I'm starting to learn Java and immediately stumbled ...
It is desirable that they chew it right on the fingers ...
Here are the data types int and flow - everything is clear: integer and fractional. But in Java there are also some double and long...
From the read Google - niasilil; only 32bit and 64...
Numbers in hex and so forth are transferred and written in the code? Or about what and where it is at all.
Z.Y.
Sorry for the stupid question, but... It's better to ask and seem stupid than not to ask and remain so.
Z.Z.Y.
Perhaps someone will be interested in taking on students, which would be just wonderful.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Ernest Farukshin, 2020-01-17
@Exebeche

int — range of valid values ​​from -2147483648 to 2147483647
long — range of valid values ​​from -9223372036854775808 to 9223372036854775807
float — range of valid values ​​from ~1.4*10-45 to ~3.4*1038
double — range of valid values ​​from ~4, 9*10-324 to ~1.8*10308
Double is more precise than float

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question