Swift is a programming language designed by Apple for creating iOS and OS X apps. Swift builds upon the foundation of C and Objective-C.

Swift is an application programming language for Apple's iOS and OS X operating systems, introduced by Apple at WWDC 2014. The language uses the LLVM compiler, with Swift code transformed into native code. Swift promises to modernize the developer experience over what Objective-C provides, offering features like:

  • generics
  • type inference
  • namespaces
  • improved safety (some protection from overflow, use-before-initialization, etc.)
  • functional programming elements (map, filter)

... among others.

The Swift syntax retains some elements from Objective-C, while providing an extensive new vocabulary for its new features.

The language can use existing iOS and OS X frameworks, like Cocoa and Cocoa Touch, and can sit side-by-side with Objective-C in applications.

Apple provides documentation here:

Code Language (used for syntax highlighting): lang-swift