• 52weeks-episode7-swift-closures

  • Mar 5 2022
  • Length: 20 mins
  • Podcast

52weeks-episode7-swift-closures  By  cover art

52weeks-episode7-swift-closures

  • Summary

  • Okay, so I'm live here with 52 weeks of Swift, Episode Seven closures, going to talk about how they work with Swift. And let's go ahead and get started, I'm going to share my screen. Let's go ahead and get this thing going here. So to start with, in Swift here, we can see that closures are self contained blocks of functionality that get passed around. And so in the world of distributed computing, which is really the world we live in with cloud computing, it's really a great strategy to have some kind of closure in your codebase. Because really, you can just pass a piece of code around, it's got everything it needs to do, its work, and then it does its work. And then it returns back result or just goes away because it's done working. So here, we can see here that you can see that there's global and nested functions. So typically, that's how the closure works, right is that you have a function with outer scope. And as an inner function, it retains that state, and then it goes through and it does its work.

    Show more Show less
activate_primeday_promo_in_buybox_DT

What listeners say about 52weeks-episode7-swift-closures

Average customer ratings

Reviews - Please select the tabs below to change the source of reviews.