js判断字符串中是否有数字和字母var reg = [0-9]var result =reg.test(string)返回true 说明有数字var reg= [a-z]ivar result = reg.test(string)返回true 有字母v2023-02-22JavaScript190