Show HN: Learn Swift

  • I've been learning Swift in recent months, and as part of that process I wrote a short book about the language.

    It's aimed at developers (like me) who can already program in a language like Ruby or Python and are looking for a quick tour of Swift.

    It's available to read for free online at http://books.aidanf.net/learn-swift

    I'll be adding stuff about yesterdays announcements in the next couple of weeks.

  • I'd highly recommend Functional Programming in Swift for more intermediate topics. By Eidhof, Kugler, and Swierstra

    http://www.objc.io/books/fpinswift/

    No affiliation to the author/book.

  • Shameless plug - I made a site that gathers resources for learning Swift. Will be adding this shortly :)

    http://www.LearnSwift.tips

  • I like the style, brevity, and practicality of the book (at least the first few chapters; haven't read it all yet). Good stuff and good luck with it.

    I did find the first few examples with the REPL to be a bit confusing. Were you using a function before it was defined?

  • Slight tangent, but are there any recommended guides/books/videos for leaning the iOS frameworks with swift?

    I have recently started programming on iOS with swift. I got my head around the language just not any of the frameworks, specifically UIKit.

  • This is very helpful. Thanks for sharing! Great that it's free too :)

  • This is fantastic, just what I was looking for, a very quick intro to swift that assumes I'm already a programmer.

    The Apple docs, at least last time I tried reading through them, were like wading through treacle so this is a great alternative! I just read the first couple of chapters in 10 minutes and got all the key info I wanted with no fluff - great job!

    One edit suggestion - I've noticed a couple of times so far that "it's" is used incorrectly, for example in this sentence:

    > You can’t change the type of a variable once you’ve declared it. It’s type is fixed at the time it is declared.

    I assume you know the error here but on the off chance you don't:

    it's = it is (it's a Bool) / its = the possessive of it (Bool is its type)

    It's a little jarring so you might want to go through and fix these.

    Cheers for the book! :-)

  • In Chapter 4, you have a typo: "dynamicly" should be "dynamically"

  • I love this. Btw, totally off topic : Is it possible to write iOS/OSX apps by learning Swift without the knowledge of ObjC ? My background : I know some Java/Ruby and do some Android apps.

  • Nice, I'm learning Swift from your site. The kerning for Chapter "10.4" is killing me though. Other than that I'm enjoying going through it. :D

  • Have just started learning Swift. Have favourited, and will be sure to give some feedback once I've made my way through the whole thing. Good luck with it!

  • Hi Aidan, your about Author section has a typo says'bulding' rather than building.

  • Looks awesome! Thanks for your time I will definitely look into it deeply soon!

  • Great another out of date book ,that will no doubt push swift 1.2 when swift 2.0 is out.

  • Thanks! probably coincidence, but seems a typical setup of keywords/chapters, the Tuts+ and some other tutorial have very similar layout.

  • Sorry, but this guide is not as comprehensive or updated as the official documentation [1]. Just compare the generics or memory management sections to see why you would want to read the official documentation. Maybe a high level tour of swift but you certainly are not going to learn swift with this guide.

    [1] https://developer.apple.com/library/ios/documentation/Swift/...