using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Chop { public static class StringHelper { public static bool ContainsNumber(string s) { foreach (char c in s.ToCharArray()) { int result; if (int.TryParse(c.ToString(), out result)) return true; } return false; } public static bool ContainsOtherChars(string s, string chars) { foreach (char c in s.ToCharArray()) if (!chars.Contains(c)) return true; return false; } } }