remove duplicate characters.