The current behavior allows writing integers as well as double without having to specify the type
let x = 1
let x = 1.0
If both spellings would create a double, it would be a bit more complicated to create an int. You just have to learn to always use a dot for decimal numbers.
3 Likes