Explore Library
Code QuizBeginner

Assignment vs Equality

Spot the operator mistake in this comparison.

Codeswift
let x = 5
if x = 5 {
    print("equal")
}

What is the bug in this code?