basic
no smicolon(“Semicolons are required, however, if you want to write multiple separate statements on a single line:”
Excerpt From: Apple Inc. “The Swift Programming Language.” iBooks. https://itun.es/in/jEUH0.l), no backet for if , for loop, while loop
let - constant
var for variable
defualt compulsory for switch, no break
All swift code is unicode.
Even u can name variable as unicode character (use option + any key)
type-safe programming language for Cocoa development.
Swift has been in development for 4 years, and was just announced this year at WWDC.
automatic type identification. The compiler infers it from what value is being set to the variable.
let π = 3.14159
let 你好 = "你好世界"
let 🐶🐮 = "dogcow”
0 comments:
Post a Comment