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 6205543
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T05:17:35+00:00 2026-05-24T05:17:35+00:00

Can anybody help me explain the following? You can type the same numbers into

  • 0

Can anybody help me explain the following? You can type the same numbers into Google and get the same results as I am getting in code….

1089.80 % 0.04 = 0
1089.84 % 0.04 = 0.04 - Surely this is wrong? 0.04 goes into 1089.84 with no remainder.
1089.88 % 0.04 = 0
1089.92 % 0.04 = 0

Similar behaviour appears for other numbers that should seemingly be correct.

Thanks in advance!

  • 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-05-24T05:17:36+00:00Added an answer on May 24, 2026 at 5:17 am

    You’re looking at the rounded values. Internally the number is not 1089.84 but something like 1089.84000026.

    If you want “correct” values, multiply both sides by 100, add 0.5, and (int) them, then take the integer mod, and convert the result back to float.

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

Sidebar

Related Questions

can anybody help me how to nice integrate doctrine 2.0 into ZF 1.10? I
Can anybody help me with retrieving some elements from the following example text: sdfaasdflj
Can anybody help me with this simple code?? #include <iostream> using namespace std; void
can anybody help with this , I can get the 3 states to work
Can anybody help me? What should be the datatype for this type -07:00:00 of
can anybody help with the code on how to add segmented control within the
I have the following problem, maybe someone can help me (or explain, where my
Can Anybody explain why this happen? This is my code in a plugin called
can anybody explain me the below code for trigger?Please note that the above code
can anybody explain why this is? here my code: <script> $(document).ready(function() { refresh(); });

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.