(String[] args)
| 14 | */ |
| 15 | public class RegexTest { |
| 16 | public static void main(String[] args) { |
| 17 | //������� |
| 18 | //String regex = "[a-zA-Z_0-9]+@[a-zA-Z_0-9]{2,8}(\\.[a-z]{2,3})+"; |
| 19 | String regex = "\\w+@\\w{2,8}(\\.[a-z]{2,3})+"; |
| 20 | |
| 21 | //����¼������ |
| 22 | Scanner sc= new Scanner(System.in); |
| 23 | System.out.println("���������䣺"); |
| 24 | String email = sc.nextLine(); |
| 25 | |
| 26 | //�� |
| 27 | boolean flag = email.matches(regex); |
| 28 | System.out.println(flag); |
| 29 | } |
| 30 | } |
nothing calls this directly
no outgoing calls
no test coverage detected