On Github DisruptiveTechnologiesMarseille / Presentation-Swift
NSString *str = @"hello,"; str = [str stringByAppendingString:@" world"];
var str = "hello," str += " world"
var numberOfApples: Int = 4 let appleSummary = "I have \(numberOfApples) apples."
var fruits = ["mango", "kiwi", "avocado"] if fruits.isEmpty { print("No fruits in my array.") } else { print("There are \(fruits.count) items in my array") }
func sayHello(personName: String) -> String { let greeting = "Hello, \(personName)!" return greeting } sayHello('Steve')
Alamofire.request(.GET, "https://www.apple.com/listDevices") .responseJSON { response in print(response) }
"bonjour".uppercaseString [10,1034,77].sort().first (1...1024).map{$0 * 2}