1595
public static bool IsNum(string input) //判断字符串是不是全部为数字 { string pattern = @"^[0-9]+$"; Regex regex = new Regex(pattern); return regex.IsMatch(input); }