Topics
Introduction
I have used Swift for windows 1.9 for debugging purpose. But you can use any Swift programming language compiler as per your availability.
func checknumbers(_ a: [Int]) -> Bool { if a.contains(4) || a.contains(8) { return true } else { return false } } print(checknumbers([2, 6, 7])) print(checknumbers([4, 8])) print(checknumbers([4, 8, 5]))
Result