{"id":65072,"date":"2025-08-01T08:00:51","date_gmt":"2025-08-01T05:00:51","guid":{"rendered":"https:\/\/wpcalc.com\/en\/?p=65072"},"modified":"2026-09-30T20:31:39","modified_gmt":"2026-09-30T17:31:39","slug":"floor-division","status":"publish","type":"post","link":"https:\/\/wpcalc.com\/en\/mathematics\/floor-division\/","title":{"rendered":"Floor Division Calculator"},"content":{"rendered":"<section class=\"not-prose calculator-box\" aria-labelledby=\"calculator-title\"><div class=\"flex items-baseline sm:items-center justify-between gap-2 sm:gap-3\"><div class=\"flex flex-col sm:flex-row sm:items-center gap-2\"><span class=\"icon icon-calculator text-primary-700! text-base! dark:text-primary-300!\" aria-hidden=\"true\"><\/span><h2 id=\"calculator-title\" class=\"text-lg font-display font-bold\">Perform Integer (Floor) Division Online<\/h2><\/div><div class=\"calcdash-favorite group\">\n  <button type=\"button\" class=\"favorite\" id=\"favorite\" data-favorite-id=\"65072\" data-favorite-title=\"Floor Division\" data-favorite-url=\"https:\/\/wpcalc.com\/en\/mathematics\/floor-division\/\" data-favorite-excerpt=\"This floor division calculator divides two numbers and rounds the result down to the nearest whole number. Enter a dividend and a non-zero divisor to get the floored quotient, useful in programming, pagination, and integer math.\" aria-label=\"Add to Favorites\" data-favorite-icon=\"icon icon-arithmetic\">\n    <span class=\"icon icon-shape-star-empty\" aria-hidden=\"true\"><\/span>\n  <\/button>\n  <div class=\"calcdash-favorite__tip\" aria-hidden=\"true\">\n   <span class=\"favorite-tooltip\" id=\"favorite-tooltip\"><\/span>\n  <\/div>\n  <span class=\"sr-only\" role=\"status\" id=\"favorite-status\"><\/span>\n<\/div><\/div><form action=\"https:\/\/wpcalc.com\/en\/mathematics\/floor-division\/\" method=\"POST\" class=\"calculator\" id=\"calculator-65072\" data-post=\"65072\"><fieldset class=\"fieldset-input\"><legend class=\"sr-only\">Input Fields<\/legend><div class=\"field has-term\" id=\"input-1\"><label for=\"field-1\">Dividend (a)<\/label><div class=\"term\">a<\/div>  <div class=\"absolute bottom-0 left-16 top-8 w-2 h-0.5 bg-blue-500\"><\/div><input type=\"number\" name=\"dividend_a\" id=\"field-1\" aria-describedby=\"calc-info-1\" step=\"1\" value=\"10\"\/><small id=\"calc-info-1\">Enter the number to be divided<\/small><\/div><div class=\"field has-term\" id=\"input-2\"><label for=\"field-2\">Divisor (b)<\/label><div class=\"term\">b<\/div>  <div class=\"absolute bottom-0 left-16 top-8 w-2 h-0.5 bg-blue-500\"><\/div><input type=\"text\" name=\"divisor_b\" id=\"field-2\" aria-describedby=\"calc-info-2\" data-number inputmode=\"decimal\" autocomplete=\"off\" spellcheck=\"false\" min=\"1\" value=\"3\"\/><small id=\"calc-info-2\">Enter the number by which to divide (must be non-zero)<\/small><\/div><\/fieldset><div class=\"buttons\"><button type=\"submit\" data-text=\"Re-Calculate\" id=\"calculate-button\" data-post=\"65072\">Calculate<\/button><button type=\"reset\">Reset<\/button><\/div><div class=\"field is-checkbox hidden!\" id=\"field-auto-calc\"><input type=\"checkbox\" id=\"auto-calc\"><label for=\"auto-calc\">Calculate automatically<\/label><small>If enabled, the result will update automatically when you change any value.<\/small><\/div><div class=\"fieldset-result is-hidden\" aria-labelledby=\"result-title\" aria-live=\"polite\" role=\"region\"> <h3 class=\"result-title bg-gradient-to-r from-primary-50 to-gray-50 dark:from-primary-900 dark:to-gray-800\" id=\"result-title\"><span class=\"icon icon-s-pulse\" aria-hidden=\"true\"><\/span> Your Results<\/h3><div class=\"result-box\"><div class=\"field-result\" id=\"output-1\"><span class=\"field-title\"><span>Floor Division Result<\/span><\/span><span class=\"field-value\" id=\"result-1\"><\/span><button type=\"button\" class=\"copy-result\" data-tooltip=\"Copy Result\" aria-label=\"Copy Result\"><span class=\"copy-icon icon icon-document-copy\" aria-hidden=\"true\"><\/span><\/button><\/div><\/div><div class=\"result-actions\"><button type=\"button\" class=\"copy-link\"><svg viewBox=\"0 0 20 20\" fill=\"currentColor\" aria-hidden=\"true\"><path d=\"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z\"\/><path d=\"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z\"\/><\/svg><span class=\"copy-link__text\">Copy link to this calculation<\/span><\/button><span class=\"sr-only\" role=\"status\" id=\"copy-link-status\"><\/span><\/div><\/div><a href=\"#respond\" class=\"hidden transition-opacity duration-300 opacity-0 w-50 text-sm justify-center items-center gap-2 px-4 py-2 rounded bg-gray-200 text-gray-700 hover:bg-gray-300\" id=\"leave-comment\"><span class=\"icon icon-comments\" aria-hidden=\"true\"><\/span>Leave a Comment<\/a><\/form><\/section><section id=\"calc-reactions\" class=\"not-prose hidden my-12 bg-gradient-to-r from-primary-50 to-gray-50 border border-indigo-100 rounded-xl px-6 py-4 shadow-sm\" data-post=\"65072\" aria-live=\"polite\" aria-labelledby=\"calc-reactions-title\"><p id=\"calc-reactions-title\" class=\"text-sm text-gray-500 text-center mb-2\">How did this result make you feel?<\/p><div role=\"group\" aria-labelledby=\"calc-reactions-title\" class=\"grid grid-cols-3 sm:flex sm:flex-row sm:justify-around gap-4 sm:items-center sm:flex-wrap\"><button type=\"button\" aria-pressed=\"false\" class=\"reaction-btn flex flex-col items-center gap-1 text-sm text-gray-700 hover:text-primary-600 cursor-pointer transition-transform hover:scale-105\" data-reaction=\"like\"><span class=\"reaction-count\" data-reaction-count=\"like\">0<\/span><span class=\"reaction text-3xl\" aria-hidden=\"true\">\ud83d\ude00 <\/span><span class=\"reaction-description font-medium\">Like <\/span><\/button><button type=\"button\" aria-pressed=\"false\" class=\"reaction-btn flex flex-col items-center gap-1 text-sm text-gray-700 hover:text-primary-600 cursor-pointer transition-transform hover:scale-105\" data-reaction=\"helpful\"><span class=\"reaction-count\" data-reaction-count=\"helpful\">0<\/span><span class=\"reaction text-3xl\" aria-hidden=\"true\">\ud83d\udca1 <\/span><span class=\"reaction-description font-medium\">Helpful <\/span><\/button><button type=\"button\" aria-pressed=\"false\" class=\"reaction-btn flex flex-col items-center gap-1 text-sm text-gray-700 hover:text-primary-600 cursor-pointer transition-transform hover:scale-105\" data-reaction=\"confused\"><span class=\"reaction-count\" data-reaction-count=\"confused\">0<\/span><span class=\"reaction text-3xl\" aria-hidden=\"true\">\ud83d\ude15 <\/span><span class=\"reaction-description font-medium\">Confused <\/span><\/button><button type=\"button\" aria-pressed=\"false\" class=\"reaction-btn flex flex-col items-center gap-1 text-sm text-gray-700 hover:text-primary-600 cursor-pointer transition-transform hover:scale-105\" data-reaction=\"disappointed\"><span class=\"reaction-count\" data-reaction-count=\"disappointed\">0<\/span><span class=\"reaction text-3xl\" aria-hidden=\"true\">\ud83d\ude1e <\/span><span class=\"reaction-description font-medium\">Disappointed <\/span><\/button><button type=\"button\" aria-pressed=\"false\" class=\"reaction-btn flex flex-col items-center gap-1 text-sm text-gray-700 hover:text-primary-600 cursor-pointer transition-transform hover:scale-105\" data-reaction=\"inaccurate\"><span class=\"reaction-count\" data-reaction-count=\"inaccurate\">0<\/span><span class=\"reaction text-3xl\" aria-hidden=\"true\">\u274c <\/span><span class=\"reaction-description font-medium\">Inaccurate <\/span><\/button><\/div><div id=\"reaction-message\" class=\"hidden mt-8 rounded-md border border-primary-100 bg-white\/50 backdrop-blur-sm px-4 py-2 text-sm text-center shadow-sm\"><\/div><\/section><div class=\"calcdash-ad not-prose calcdash-ad--calc_result calcdash-ad--in-article\"><ins class=\"adsbygoogle\" style=\"display:block\" data-ad-client=\"ca-pub-1721569815777345\" data-ad-slot=\"6317458308\" data-ad-layout=\"in-article\" data-ad-format=\"fluid\"><\/ins><script>(adsbygoogle = window.adsbygoogle || []).push({});<\/script><\/div>\n<style id=\"wpcoderpro-inline-1\">.formula-box {\r\n\tborder-bottom: none !important;\r\n}<\/style><section class=\"formula-box\" aria-labelledby=\"formula-title\">\r\n\t<div id=\"formula-title\" class=\"not-prose font-display mb-4\"><span class=\"icon icon-formula\" aria-hidden=\"true\"><\/span><h2>Floor Division Formula<\/h2><\/div>\r\n\t<figure class=\"not-prose formula\">\r\n\t\t<figcaption class=\"formula-title\">Formula<\/figcaption>\r\n\t\t<div class=\"text-base text-gray-800\" id=\"formula\">\n\\[ a \\mathbin{\\mathrm{div}} b = \\left\\lfloor \\frac{a}{b} \\right\\rfloor \\]\n<\/div>\r\n\t<\/figure>\r\n\t<\/p>\n<p><strong>Where:<\/strong><\/p>\n<ul>\n<li>\\(a\\) \u2014 the dividend, the number being divided<\/li>\n<li>\\(b\\) \u2014 the divisor, the number you divide by (\\(b \\neq 0\\))<\/li>\n<li>\\(\\lfloor \\cdot \\rfloor\\) \u2014 the floor function, which rounds a real number down to the greatest integer less than or equal to it<\/li>\n<\/ul>\n<p>The formula states that floor division equals the ordinary quotient \\(a \/ b\\) rounded down to the nearest integer. In many programming languages this operation is written with the operator \\(a \\mathbin{\/\/} b\\), as in Python.<\/p>\n<p>\r\n<\/section>\n<style id=\"wpcoderpro-inline-459\">.calculation-box {\r\n\tborder-bottom: none !important;\r\n}<\/style><section id=\"calculation\" class=\"calculation-box\" aria-labelledby=\"calculation-title\">\r\n\t<div id=\"calculation-title\" class=\"not-prose font-display\"><span class=\"icon icon-unordered-list\" aria-hidden=\"true\"><\/span><h2>Floor Division \u2013 Calculation Example<\/h2><\/div>\r\n\r\n<\/p>\n<p><strong>Example:<\/strong> you want to split 10 items evenly into groups of 3 and need to know how many complete groups you can make.<\/p>\n<p>\\[ \\frac{10}{3} = 3.\\overline{3} \\quad \\Rightarrow \\quad \\left\\lfloor \\frac{10}{3} \\right\\rfloor = 3 \\]<\/p>\n<p><strong>Result:<\/strong> \\(10 \\mathbin{\/\/} 3 = 3\\). Three complete groups can be formed, with 1 item left over (the remainder \\(10 \\bmod 3 = 1\\)).<\/p>\n<p><strong>With a negative dividend:<\/strong> \\(-7 \\mathbin{\/\/} 2 = \\lfloor -3.5 \\rfloor = -4\\), because floor division always rounds <em>down<\/em>, not toward zero.<\/p>\n<p>\n\r\n<\/section>\n<h2>How to use the calculator<\/h2>\n<ol>\n<li>Enter the <strong>Dividend (a)<\/strong> \u2014 the number you want to divide. The default value is 10.<\/li>\n<li>Enter the <strong>Divisor (b)<\/strong> \u2014 the number to divide by. It must be non-zero; the calculator rejects a divisor of 0. The default value is 3.<\/li>\n<li>Read the <strong>Floor Division Result<\/strong> \u2014 the quotient of the two numbers rounded down to the nearest whole number.<\/li>\n<\/ol>\n<p>The calculator updates instantly as you change either input, and it accepts negative dividends as well as positive ones.<\/p>\n<h2>What is floor division?<\/h2>\n<p>Floor division is a form of integer division that returns the largest whole number less than or equal to the true quotient. Ordinary division of 10 by 3 gives 3.333\u2026, but floor division discards the fractional part by rounding <em>down<\/em>, giving 3. This differs from simple truncation when negative numbers are involved: truncating \\(-7\/2 = -3.5\\) toward zero gives \\(-3\\), while flooring it gives \\(-4\\).<\/p>\n<p>The operation appears throughout mathematics and computing. In Python it is the <code>\/\/<\/code> operator; in many other languages (C, Java, JavaScript) integer division of positive numbers behaves the same way, though negative operands are often truncated toward zero instead of floored. Related concepts include the <a href=\"https:\/\/wpcalc.com\/en\/mathematics\/division-calculator\/\">Division<\/a> operation itself and the modulo operation, since every division with a remainder satisfies \\(a = b \\lfloor a\/b \\rfloor + (a \\bmod b)\\).<\/p>\n<p>Floor division matters whenever only whole units make sense. If you have 10 apples and pack them into boxes of 3, you can fill exactly \\(\\lfloor 10\/3 \\rfloor = 3\\) boxes. If a web page shows 10 results per page, \\(\\lfloor n\/10 \\rfloor\\) tells you how many complete pages \\(n\\) items fill \u2014 the basis of pagination logic in nearly every website and database query.<\/p>\n<h2>Common applications<\/h2>\n<ul>\n<li><strong>Pagination:<\/strong> computing the number of full pages or the index of the page containing a given item.<\/li>\n<li><strong>Indexing and slicing:<\/strong> converting a linear index into row\/column coordinates, e.g. row = <code>index \/\/ columns<\/code>.<\/li>\n<li><strong>Time conversions:<\/strong> converting 130 seconds into minutes uses \\(\\lfloor 130\/60 \\rfloor = 2\\) minutes with 10 seconds remaining.<\/li>\n<li><strong>Scheduling and grouping:<\/strong> splitting people into teams or items into batches of fixed size.<\/li>\n<li><strong>Number theory:<\/strong> floor division underpins the <a href=\"https:\/\/wpcalc.com\/en\/mathematics\/multiplicative-inverse-modulo\/\">multiplicative inverse modulo<\/a>, the <a href=\"https:\/\/wpcalc.com\/en\/mathematics\/chinese-remainder-theorem\/\">Chinese Remainder Theorem<\/a>, and other calculations that rely on quotients and remainders.<\/li>\n<li><strong>Loop iterations:<\/strong> algorithms such as binary search, tree traversals, and divide-and-conquer use halving via \\(\\lfloor n\/2 \\rfloor\\) at every step.<\/li>\n<\/ul>\n<h2>Assumptions and limitations<\/h2>\n<ul>\n<li><strong>Division by zero is undefined:<\/strong> the calculator shows an error if the divisor is 0, just as ordinary division does.<\/li>\n<li><strong>Rounding direction:<\/strong> the result is always rounded <em>down<\/em> (toward negative infinity), not toward zero. This matches Python's <code>\/\/<\/code> operator, but differs from integer division in C and Java, which truncate toward zero for negative operands.<\/li>\n<li><strong>No remainder shown:<\/strong> this tool returns only the floored quotient. To also get the leftover amount, compute the remainder \\(a - b \\cdot (a \\mathbin{\/\/} b)\\) \u2014 for the default example, \\(10 - 3 \\cdot 3 = 1\\).<\/li>\n<li><strong>Fractional inputs:<\/strong> although typical use involves whole numbers, the calculator accepts decimal values; the quotient is still floored to a whole number.<\/li>\n<\/ul>\n<p>For plain division with decimals, use the <a href=\"https:\/\/wpcalc.com\/en\/mathematics\/division-calculator\/\">Division calculator<\/a>; for the other basic operations, see the <a href=\"https:\/\/wpcalc.com\/en\/mathematics\/multiplication-calculator\/\">Multiplication<\/a> and <a href=\"https:\/\/wpcalc.com\/en\/mathematics\/subtraction-calculator\/\">Subtraction<\/a> calculators.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This floor division calculator divides two numbers and rounds the result down to the nearest whole number. Enter a dividend and a non-zero divisor to get the floored quotient, useful in programming, pagination, and integer math.<\/p>\n","protected":false},"author":3168,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[7],"tags":[72],"class_list":["post-65072","post","type-post","status-publish","format-standard","hentry","category-mathematics","tag-arithmetic-calculators"],"acf":[],"_links":{"self":[{"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/posts\/65072","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/users\/3168"}],"replies":[{"embeddable":true,"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/comments?post=65072"}],"version-history":[{"count":3,"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/posts\/65072\/revisions"}],"predecessor-version":[{"id":66238,"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/posts\/65072\/revisions\/66238"}],"wp:attachment":[{"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/media?parent=65072"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/categories?post=65072"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpcalc.com\/en\/wp-json\/wp\/v2\/tags?post=65072"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}