// Removes special characters from a string public string RemoveSpecialChars(string input, string specialChars) { return Regex.Replace(input, specialChars, string.Empty); } // Reverses a string public string Reverse(string input) { if (string.IsNullOrWhiteSpace(input)) { return input; } char[] array = input.ToCharArray(); Array.Reverse(array); return new String(array); }
Some string utilities
最新推荐文章于 2024-07-29 13:29:00 发布