Hey guys.
Cannot convert value of type '[Int]' to expected argument type 'Int'
What am I doing wrong?
Any help appriciated.
Thank You
Code Block var d = 5var s = "String of words"var words = s.split(separator: " ")var howMany = words.countvar howLong = words[2].countvar result = [words[0].count]for b in 0..<howMany { var tem = words[0].count if result > tem { result = tem } }
line 8 and 9 displays the following info:Cannot convert value of type '[Int]' to expected argument type 'Int'
What am I doing wrong?
Any help appriciated.
Thank You