You are viewing a single comment's thread. Return to all comments →
not a big deal... for simplicity you could have used: for (char c:str.toCharArray()) for (char c:prefix.toCharArray()) { instead of
for (int i = 0; i < str.length(); i++)
and
for (int i = 0; i < prefix.length(); i++)
Seems like cookies are disabled on this browser, please enable them to open this website
Tries: Contacts
You are viewing a single comment's thread. Return to all comments →
not a big deal... for simplicity you could have used: for (char c:str.toCharArray()) for (char c:prefix.toCharArray()) { instead of
for (int i = 0; i < str.length(); i++)
and
for (int i = 0; i < prefix.length(); i++)