[C#] C#正则匹配是否是正确的ip地址 →→→→→进入此内容的聊天室

来自 , 2020-07-13, 写在 C#, 查看 109 次.
URL http://www.code666.cn/view/316282dd
  1. public static bool IsIP(string input)
  2.         {
  3.             Regex regex = new Regex("^\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}$");
  4.             return regex.IsMatch(input);
  5.         }

回复 "C#正则匹配是否是正确的ip地址"

这儿你可以回复上面这条便签

captcha