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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T20:27:47+00:00 2026-06-03T20:27:47+00:00

why is Math.floor(Double.MIN_VALUE) == 0 ? can any one send me the java algorithme

  • 0

why is Math.floor(Double.MIN_VALUE) == 0 ?
can any one send me the java algorithme of Floor function or at least explain this result please?

  • 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-03T20:27:49+00:00Added an answer on June 3, 2026 at 8:27 pm

    Double.MIN_VALUE doesn’t mean what you think it means. It means “the smallest positive double value” – so naturally when you take the “floor” of it (largest integer less than or equal to the value), you’ll get 0. Documentation:

    A constant holding the smallest positive nonzero value of type double, 2-1074. It is equal to the hexadecimal floating-point literal 0x0.0000000000001P-1022 and also equal to Double.longBitsToDouble(0x1L).

    I agree that the name is confusing, but it’s always worth checking the documentation as soon as you see confusing behaviour.

    If you want to get the “lowest” finite double, just use -double.MAX_VALUE.

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

Sidebar

Related Questions

This question is about the threshold at which Math.Floor(double) and Math.Ceiling(double) decide to give
Are there any reasons one would prefer to use Math.Floor vs casting to an
I have this javascript: $('.foto').filter(function(index) { return index == Math.floor(Math.random() * 8) + 1;
I have this custom function to calculate MD5 hash, written in Java. I can't
In function is transmited double. function writebyte(id, data) { data = Math.floor(data); buf[id] =
$(function() { var number = document.getElementById(breuken); var i=0; for (i=1;i<=10;i++){ var fRandom = Math.floor(Math.random()*10);
I have a function that looks like so: window.attack = function(enemyHealth){ attackChance = Math.floor(Math.random()*11);
I'm playing around with code like this: <s:Button id=test label=test transformX={Math.floor(test.width/2)} rotationY=20 x=20 y=20
I have this bookmarklet: javascript:void(window.open(document.links[Math.floor(Math.random()*document.links.length)].href,'_blank')) It outputs random link from a document full of
I have: function getRandomInt(min, max){ return Math.floor(Math.random() * (max - min + 1)) +

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.