Problem:
https://www.hackerrank.com/contests/regular-expresso/challenges/restricted-repetitionsThis solution solves the test cases partially.
Solution:
public class Solution {public static void main(String[] args) {
Regex_Test tester = new Regex_Test();
tester.checker("(?=^(hh+)\1+(aa+)\2+(?<=a)(cc)+(?=k)(?<=c)k(kk)*`$)(?=.*a{6,})(?=.*(?<=c)k{5,21}(?=$`))"); // Use \\ instead of using \
}
}
No comments:
Post a Comment