+91 9945200008     support@uttaracomputers.com
LOGIN     REGISTER    

Unsigned Float in C ??

0
0

Question by Sri Mahesh Burukule :

Why there is no unsigned float defind in C ?

 

  • You must to post comments
0
0

unsigned is a restricted data type useful only for integers ( int  short  and long ).  Regular int’s can be used very well for positive only numbers  but the range would be just half since the negative representations are not used.  Using unsigned makes it possible to use entire range as positive numbers.  float already has a huge range ( 2 to the power 127  OR  10 to to power 40 approx. ).  There is no need to extend the range to use only positive fractional numbers.  We might as well used the signed representation for positive only fractional numbers too.

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.