Get rid of the labels in the isSubstringPresent method, but preserve its logic. The method returns true if substring is a substring of string, otherwise false. The code should not have break and continue statements.
Getting rid of labels
You must be signed in to leave a comment
28 March 2022, 23:18
LOL, this is laughably easy to pass using Java's built-in String.contains method. I'm surprised the validation lets you do it.
24 May, 17:03
Haha, I forgot about this method. What's worse is that I used it a couple of days ago and relied on a counter to solve this task. -_-
4 August 2020, 18:11
@CodeGym: There's a typo in requirement #2. Should be "[...] must return false if substring is NOT a substring of string."
7 August 2020, 06:14
Thanks, it will be fixed soon