kotlin contains string example
Example 1: kotlin contains
var word = "grepper"
if(word.contains("pp")) {
println("yes")
}
Example 2: kotlin check if string contains
"AbBaCca".contains("bac", ignoreCase = true)
var word = "grepper"
if(word.contains("pp")) {
println("yes")
}
"AbBaCca".contains("bac", ignoreCase = true)