Remove duplicate strings - C#
Here is the code
1 2 3 | var words = new HashSet(); string text = "praveen kumar thalluri praveen kumar thalluri"; text = Regex.Replace(text, "\\w+", m => words.Add(m.Value.ToUpperInvariant())? m.Value: String.Empty); |
Comments
Post a Comment