Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8205861
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T08:26:14+00:00 2026-06-07T08:26:14+00:00

I have a question which deals with the difference in representation between a float

  • 0

I have a question which deals with the difference in representation between a float and a byte in a computer system. So for instance how does a float convert from a float to and int and back; it results in a completely different representation of the bytes. Are there any resources I could use to point me in the right direction? Any help is much appreciated! I cannot find anything online, a link in the right direction would be very helpful!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T08:26:15+00:00Added an answer on June 7, 2026 at 8:26 am

    The most common encoding of floating-point numbers uses IEEE 754. For single-precision numbers, there is a sign bit (s), 8 exponent bits (e), and 23 fraction bits (f).

    For most values of s, e, and f, the value represented is -1s•2e-127•F, where F is the number you get by writing “1.” followed by the 23 bits of f and then interpreting that string as a binary numeral. E.g., if f is 10000000000000000000000, then the binary numeral is 1.10000000000000000000000, which is (in decimal) 1.5, so F is 1.5.

    The above holds whenever 0 < e < 255. The values 0 and 255 are special.

    When e is 0, the value represented is the same as above except that you start F with “0.” instead of “1.”. In particular, if f is zero, then the value represented is zero. If f is not zero, these are called denormal numbers, because they are smaller than the normal values represented in the primary way above.

    When e is 255 and f is 0, the value represented is +infinity or -infinity, according to the sign bit, s. When e is 255 and f is not zero, the value represented is called a NaN, Not a Number, which is used for debugging or catching errors or other special purposes. There are quiet NaNs (which do not cause traps; they are typically used when you want to continue calculations to get a final result, then figure out what to do about a NaN) and signaling NaNs (which do cause traps; they are typically used when you want to abort a calculation because an error has occurred).

    There may be variations in how the encoding appears on different platforms, especially the ordering of bytes within the 32 bits. And some platforms do not use IEEE 754 encodings.

    Double-precision encoding uses the same scheme, except e is 11 bits, the 127 (called the exponent bias) is changed to 1023, and f is 52 bits. Also the special value for the exponent is its 11-bit maximum, 2047, rather than the 8-bit maximum, 255.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a question which I am sure is simple but I have slight
I have a question which is slightly similar to this question on stackoverflow std::cin.clear()
I have a question which is described below: What problems would arise for testing
I have a question which I think involves conditional entropy in the field of
I have a question which may be somewhat silly because I'm pretty sure I
I have a question which involves calling a function with 2 parameters of a
Hey guys i have a question which i have been looking for the answer
this is my first time posting here, I have a question which I have
I have this question in which I have a SQL Server Compact Edition database
I have few Question for which I am not able to get a proper

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.