While working with java code linting and formatting I was getting error to remove all consecutive capital letters in variables, classs, function name. So to find all those words in source code this regex worked.
Example:-
- testSTring ---> match
- testString ---> no match
- TEstString ---> match
- teststrING ---> match
CodePudding user response:
The correct regex :-
([A-Z]{2,})