<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>ts0818</author_name>
  <author_url>https://blog.hatena.ne.jp/ts0818/</author_url>
  <blog_title>ts0818のブログ</blog_title>
  <blog_url>https://ts0818.hatenablog.com/</blog_url>
  <categories>
    <anon>Java</anon>
  </categories>
  <description>List型の変数に、ArrayListのインスタンスを代入してたわけですが、 List&lt;integer&gt; select = new ArrayList&lt;integer&gt;(); // 途中省略 select.set(0, 0); select.set(1, 1); select.set(2, 2); とか、やって見事に怒られるわけですが、結論は、ArrayListのインスタンスに要素が1つも作られていないのに、値をセットしようとしたためでした。 配列のように、最初に要素数を決めなくてもいいためウッカリしてましたが、ArrayListも初期化処理をしないと、要素数が0になってしまっているので、イン…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fts0818.hatenablog.com%2Fentry%2F2017%2F07%2F22%2F105824&quot; title=&quot;Java ListでIndexOutOfBoundsExceptionって起きてるけど - ts0818のブログ&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>https://cdn-ak.f.st-hatena.com/images/fotolife/t/ts0818/20170722/20170722105557.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2017-07-22 10:58:24</published>
  <title>Java ListでIndexOutOfBoundsExceptionって起きてるけど</title>
  <type>rich</type>
  <url>https://ts0818.hatenablog.com/entry/2017/07/22/105824</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
