Comparison of double and float primitive types in C#


Precision states the difference between float and double data type.

Float is a single precision (32 bit) floating point data type.

Double is a double precision (64 bit) floating point data type.

Range of a float type −

-3.4 x 1038 to + 3.4 x 1038

Range of a double type is −

(+/-)5.0 x 10-324 to (+/-)1.7 x 10308

Default value of a float type −

0.0F

Default value of a double type −

0.0D

Updated on: 30-Jul-2019

294 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements