<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>suzaku114</author_name>
  <author_url>https://blog.hatena.ne.jp/suzaku114/</author_url>
  <blog_title>混沌とした備忘録</blog_title>
  <blog_url>https://noboru.hatenablog.jp/</blog_url>
  <categories>
    <anon>Java</anon>
  </categories>
  <description>doubleは浮動小数点型なので（？）、小数を正確に表現できないことは知ってました。 で、BigDecimalに変換する際に失敗しました。 以下、やっちゃった間違い。 double d = 0.1; BigDecimal b = new BigDecimal(d); System.out.println(b);上記の出力結果 0.1000000000000000055511151231257827021181583404541015625 で、0.1を保持するBigDecimalオブジェクトを作成したい場合、 &quot;0.1&quot;という文字列よりBigDecimalを作成する必要があるらしい。 それを簡…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fnoboru.hatenablog.jp%2Fentry%2F20101207%2F1291720512&quot; title=&quot;BigDecimalとdoubleの変換について - 混沌とした備忘録&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2010-12-07 20:15:12</published>
  <title>BigDecimalとdoubleの変換について</title>
  <type>rich</type>
  <url>https://noboru.hatenablog.jp/entry/20101207/1291720512</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
