swift check if a string contains a substring code example
Example: How do I check if a string contains another string in Swift
let string = "hello Swift"
if string.contains("Swift") {
print("exists")
}
let string = "hello Swift"
if string.contains("Swift") {
print("exists")
}