struct Point { var x: Int; var y: Int } let p = Point(x: 1, y: 2) // p.x = 5 would not compile: p is a constant struct var q = p q.x = 5 print(p.x, q.x)
its properties cannot change