<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Clojure Q&amp;A - Recent questions tagged bigdecimal</title>
<link>https://ask.clojure.org/index.php/tag/bigdecimal</link>
<description></description>
<item>
<title>Why do BigInt literals not require N suffix, but BigDecimals do?</title>
<link>https://ask.clojure.org/index.php/8510/why-do-bigint-literals-not-require-suffix-but-bigdecimals-do</link>
<description>&lt;p&gt;I find it a bit inconsistent that I can type:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;123423534634544234534634645342363462443649886756676645466767687
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;And it will auto-promote it to a BigInt to fit, without me needing to specify so with the N suffix.&lt;/p&gt;
&lt;p&gt;But if using decimal:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;12.3423534634544234534634645342363462443649886756676645466767687
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;It won't auto-promote to BigDecimal without explicitly adding an M suffix. Instead it'll truncate to double precision. &lt;/p&gt;
&lt;p&gt;Any reason why that is?&lt;/p&gt;
</description>
<category>Syntax and reader</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/8510/why-do-bigint-literals-not-require-suffix-but-bigdecimals-do</guid>
<pubDate>Tue, 03 Sep 2019 19:28:00 +0000</pubDate>
</item>
</channel>
</rss>