I've searched a way to check in Swift if a string contains particular characters and just them. For exemple, if a string contains them but it contains other characters as well, it should return false
.
What I need is something which allows me to say if a string contains JUST some elements. For exemple: If I wanna know if "101010010101"
contains ONLY 1 and 0 it should return true
. But "1901919117"
doesn't contains ONLY 1 and 0 it should return false
.