You are viewing a single comment's thread. Return to all comments →
public String pattern = String.format("^%1s\.%1s$", "((\d{1,2})|((0|1)\d{2})|(2[0-4]\d|25[0-5]))");
Seems like cookies are disabled on this browser, please enable them to open this website
I agree to HackerRank's Terms of Service and Privacy Policy.
Java Regex
You are viewing a single comment's thread. Return to all comments →
public String pattern = String.format("^%1s\.%1s$", "((\d{1,2})|((0|1)\d{2})|(2[0-4]\d|25[0-5]))");