title: Add header at top for the spinner array in android
body: <pre><code>Using the code below and add it to the spinner. The ObjectList contains the list as below
  
  
          HashSet&lt;String&gt; hashSet = new HashSet&lt;String&gt;();
          hashSet.add(&quot;Select Object&quot;);
          hashSet.addAll(ObjectList);
          ObjectList.clear();
          ObjectList.addAll(hashSet);
  </code></pre>
  <p>ObjectList</p>
  <pre><code>{ &quot;Paper&quot;, &quot;Pen&quot;, &quot;Pencil&quot;, &quot;Ink&quot;, &quot;Other&quot;}
  </code></pre>
  <p>The expected output is</p>
  <pre><code>{ &quot;Select Object&quot;, &quot;Paper&quot;, &quot;Pen&quot;, &quot;Pencil&quot;, &quot;Ink&quot;, &quot;Other&quot;}
  </code></pre>
  <p>Instead I'm getting</p>
  <pre><code>{ &quot;Paper&quot;, &quot;Pen&quot;, &quot;Pencil&quot;, &quot;Select Object&quot;, &quot;Ink&quot;, &quot;Other&quot;}  OR
  { &quot;Paper&quot;, &quot;Select Object&quot;, &quot;Pen&quot;, &quot;Pencil&quot;, &quot;Ink&quot;, &quot;Other&quot;}
  </code></pre>
  <p>depending on whether I place the code &quot;hashSet.add(&quot;Select Object&quot;);&quot; before or after .addAll</p>
  <p>How to get the Select Object to the top?</p>