Remove Duplicated Characters In Given String
In a given string, the following code removes duplicated characters within O(n) time and does not increase memory space:
Sourcecode is here. Many thanks to Xuan, Yinghai and Shiqi.
This entry was posted
on Tuesday, January 24th, 2006 at 11:47 pm and is filed under English, Programming.
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or trackback from your own site.
March 25th, 2006 at 2:49 am
try “aba”
March 25th, 2006 at 6:27 pm
wangy22@linux ~/code/C $ ./CheckDup
aba
aba
March 26th, 2006 at 1:21 pm
what is the specification of the the code?
March 26th, 2006 at 3:17 pm
Remove duplicated characters in given string,
not reduce same characters to 1 character.
March 28th, 2006 at 2:31 am
in string “aba”, “a’ is duplicated, right?
March 28th, 2006 at 9:18 am
In “aab”, ‘a’ is.
September 23rd, 2007 at 9:39 pm
Try “Potato”
October 8th, 2007 at 9:15 pm
# Yu Wang Says:
March 28th, 2006 at 9:18 am
In “aab”, ‘a’ is.
this is such a trivial problem then…=.=