Find a substring from a given string | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Find a substring from a given string

Find a substring from a given string e.g findSubString(str: String, substring: String) This function should return true if the string in the main string or false if it is not; Scenario given a string ā€œWellcome hereā€ should return true if we look for ā€œcomeā€ from it and false if we look for ā€œbackā€

10th Aug 2022, 8:21 AM
Hope Mwale
Hope Mwale - avatar
2 Answers
+ 2
Hope Mwale You have to post your try....
10th Aug 2022, 8:28 AM
KrOW
KrOW - avatar
+ 2
Hope Mwale Also tag your language so you can get the right people to respond
10th Aug 2022, 11:01 AM
Rik Wittkopp
Rik Wittkopp - avatar