+ 1

doubles: how do they differ to int?

12th May 2016, 9:00 AM
Chris Nangle
Chris Nangle - avatar
3 Respostas
+ 4
doubles are numbers with decimals, e.g. 7.15, 47.88 int are whole numbers, e.g.: 5, 42, 88
19th May 2016, 2:26 PM
James Flanders
+ 4
Int is whole numbers. They also differ in byte size. Doubles take up more space than int, and is therefore heavier to run for the program.
14th Jun 2016, 1:43 AM
Vegard Bratteng
Vegard Bratteng - avatar
+ 2
Doubles are used to store large decimal numbers and it's size is 4 or 8 bytes. Int is used to store whole numbers. its size is 2 or 4 bytes
1st Jul 2016, 8:31 AM
Midhun Mathew