edited by
1,837 views

2 Answers

Best answer
5 votes
5 votes

First Read This

Now , Try for

  • Explicit Representation
  • Double Precision Representation

Extra Note

#include <stdio.h>
int main(int argc, char const *argv[])
{
float a = 1.1;
if(a==1.1)
  printf("if");
else
printf("else");
}

The output of the above program will be : "else"

#include <stdio.h>
int main(int argc, char const *argv[])
{
float a = 2.5;
if(a==2.5)
  printf("if");
else
printf("else");
}

The output of the above program will be : "if else"

edited by
4 votes
4 votes

1.1
already in implicit normalised form with S=0,M=1 and E=0 means 0+127=127 for single precision and 1023 for double precision
m writing as S(1) E(8/11) M(23/52)

IEEE 754 single precision=
0 01111111 10000000000000000000


IEEE 754 double precision=
0 011111111111 10000000000000000000000000000000000000000000000000

Related questions

5 votes
5 votes
2 answers
1
gate_forum asked Oct 14, 2015
1,268 views
32 bit floating point representation of decimal number 3.284*10^4 is(A) 010001101111110111000000000000(B) 110001101111110111000000000000(C) 011010101111110111000000..(D) ...