error cannot assign value of type int to string swift - what am I doing wrong?
joshuam6060

print("guess a number that I thought of")
let number = Int.random(in: 0...100)
var z = readLine()
if z = number{
print("yay")
}

You are viewing a single comment. View All
Coder100

oh right, z can be optional.

@joshuam6060