Posts

Showing posts with the label unwrapping

Stephen DeStefano Swift 5 Course - Part 6 (Lectures 23 to 25)

Image
Yes cracking on! Got a bit of time this morning before heading to my Uncle's and Auntie's. I want to cover Optionals then Control Flow. All very doable! Let's go! Start Time - 08:19 Optionals So I know about these but good to go over! They're used in situations where they may not be a value stored. Nil means the absence of a valid object. You can do these for any type at all. Optional types are returned where there may not have been a value e.g. when converting from string number to actual int number. The question mark syntax. Good way of understanding this is that the ? QUESTIONS whether something may not have a value. So the question bit is key there! You can only use nil with optionals. Optionals can only be var as the values are likely to change. If you create an optional without an initial value then it automatically sets this to nil. Forced unwrapping Comparing the optional against nil.... That's not forced unwrapping - that's just ch...

Bob Lee Course Part 1 (Lectures 1 to 4)

Image
A new course! Yes, it may seem random and rash to suddenly change tack like this. However, while I was working on the Clima project, I realised that great as Angela's course is, it's not up to date. I resent paying for the new one and redoing what I already had done, just to ensure that there's nothing redundant. Basically, I reckon it makes more sense to focus on a new, fresh course that is actually at an INTERMEDIATE level! I loved Bob's explanations on delegates before and have actually paid more: £31.99 for this (usually around £10 to £12), though I did get an added discount. Anyway, I want to see how this goes and feel like I'm ready to be going in deeper with concepts I know well now.  Just gonna do a max of half an hour today. Here we go! Start Time - 20:33 Couple of things to get started - Swift Community to join and eBook to download. OK all done! Bob makes it clear that this is not for beginners. I'm glad I am - I feel like I know the syntax we...