How to compare [String]? and String in Swift in swift 5 code example Example: swift compare strings print("foo".elementsEqual("bar")) //false