62,046
社区成员
发帖
与我相关
我的任务
分享
protected void test()
{
string dirtyStr = "一起|一同|到|去|在|与|等人";
Regex validateReg = new Regex("^((?!" + dirtyStr + ").(?<!" + dirtyStr + "))*$", RegexOptions.Compiled | RegexOptions.ExplicitCapture);
string str = "一起去上海看人";
Response.Write(validateReg.IsMatch(str));
}