regular expressions password contains number code example Example: regular expressions password contains number "^(?=.*[A-Za-z])(?=.*\d)[A-Za-z\d]{8,}$"