In java, how to append string ignoring duplicates
<p>I have string say "ABC,D" , now I wish to write a method  <code>append(initialStr, currStr )</code> which appends <code>currStr</code> to <code>initailStr</code> only if currstr is not already present in <code>initialStr</code>. I tried a method which splits with comma, but since my string contains comma so that method doesn't works for me. Any help will be greatly appreciated.</p>
