Angela Yu Xcode 12 Course - Part 21 (lectures 193 to 197)
Yes, so I have found some sort of rhythm, hence another entry today! Just continue from where we got to.... *Ended up continuing from 4th April instead! Start Time - 17:09 Swift Closures (advanced Swift!) My understanding of these is that they are like functions without a specific name. So they can be shorter/easier etc. I tried conceptualising them before with Bob's course but it was at that point that I gave up on them! Function - bread analogy. An input with a machine that cuts up the bread, then an output (sliced bread!). Three variations on functions - 1.Those that do something without any input/parameters or have an output 2. Those that take an input with no specific output 3. Those that take an input and give an output So closures are a step beyond that! Simple function - with input, output and something that happens. Then an adding one, which we're going to use into the original function... Here's how it now looks - Ahh so I can pa...