How to Avoid printing duplicate special characters in string? : <p>I have a String which includes special characters. and i want to print them but not the duplicate ones.</p>

<pre><code>Input String s="&amp;*$%) )_@*% &amp;)((("
Ouput ="&amp;*$%)_@("
</code></pre>
