Java tutorial
//package com.java2s; import java.util.regex.Matcher; import java.util.regex.Pattern; public class Main { public static boolean isMobilePhoneNumber(String number) { String regx = "^(13[0-9]|15[0-9]|18[0-9]|14[5|7])\\d{8}$"; Pattern pattern = Pattern.compile(regx); Matcher matcher = pattern.matcher(number); return matcher.find(); } }