reduce, filter, removeAll

  Рет қаралды 3,332

Stewart Lynch

Stewart Lynch

4 жыл бұрын

This is the second in a series of videos on higher order functions in Swift. In this video we look at reduce, filter and removeAll
Starter Playground:
www.createchsol.com/StarterPro...
Videos in this series
Part 1: map, compactMap, flatMap: • map, compactMap flatMap
Part 2: reduce, filter, removeAll: • reduce, filter, removeAll
Part 3: contains, forEach, sorted, • contains, forEach, sorted
Stewart Lynch's KZfaq Channel
/ stewartlynch
CreaTECH Solutions Website
www.createchsol.com
Stewart Lynch's GitHub
github.com/StewartLynch

Пікірлер: 32
@joeprince7509
@joeprince7509 3 жыл бұрын
Your style of teaching is hands-down one of the simplest and most straightforward that I have seen here on KZfaq. I absolutely love it, and will remember the functions and way to use them because of your approach. Thank you!
@atalayasa2772
@atalayasa2772 4 жыл бұрын
Even if I have knowledge these functions it was worth to watch thank you..
@siddharthkothari007
@siddharthkothari007 4 жыл бұрын
Very good narration with some easy to grasp examples.
@ayon3527
@ayon3527 4 жыл бұрын
always a refresher!!
@chrisrylie71
@chrisrylie71 4 жыл бұрын
Thank you Stewart for sharing your knowledge
@subhashr.p7643
@subhashr.p7643 2 жыл бұрын
Great video.. Learnt lot with this. Very helpful
@sakshipatil9537
@sakshipatil9537 2 жыл бұрын
🙌🙌
@taglass75
@taglass75 4 жыл бұрын
I have a very minor correction. The ‘?’ operator as used in your heavy weights reduce example is the ternary conditional operator, not the nil coalescing operator ‘??’. Great videos though. The presentation is easy to understand, and you are a good narrator.
@danielbyrne
@danielbyrne 3 жыл бұрын
Gold
@user-me3xd5he2d
@user-me3xd5he2d Жыл бұрын
Thank you for the video. I don't know why I have such trouble taking what I learn and knowing how to apply it to a real Xcode project, but I always do with playground stuff. I get errors like :
@kapilsardana5053
@kapilsardana5053 4 жыл бұрын
Hi Stewart, I have a question regarding sync,async dispatch queues. For example
@jankuna9479
@jankuna9479 Жыл бұрын
Hi Stewart, thanks for your work.
@gamblethedog
@gamblethedog 3 жыл бұрын
How about this one: let totalSalary = employee.map{ $0.salary }.reduce(0,+)
@dibjr
@dibjr Жыл бұрын
Stewart, is there something in Xcode that allows you to display the value of a variable inline in the playground, or is that a graphical display thing you are doing in your videos? (example at
@anhhanry7167
@anhhanry7167 2 жыл бұрын
the filltered array returns only an array of single element ( that fits the condition ) , but what if we want to return an array of struct that contains the condition, i.e. if we want to filter the person ( a struct ) with age > 5 ( in the clip -> get and array of name returned ) : how do we get an array of the person ( a struct) returned ?
contains, forEach, sorted
18:06
Stewart Lynch
Рет қаралды 2,1 М.
map, compactMap flatMap
17:06
Stewart Lynch
Рет қаралды 8 М.
What it feels like cleaning up after a toddler.
00:40
Daniel LaBelle
Рет қаралды 91 МЛН
CHOCKY MILK.. 🤣 #shorts
00:20
Savage Vlogs
Рет қаралды 15 МЛН
Red❤️+Green💚=
00:38
ISSEI / いっせい
Рет қаралды 91 МЛН
Fast and Furious: New Zealand 🚗
00:29
How Ridiculous
Рет қаралды 45 МЛН
Is this the Perfect Charger for All Your Needs?
9:45
LCA Digital Media
Рет қаралды 9
Xcode Frameworks and Workspaces
19:20
Stewart Lynch
Рет қаралды 1,6 М.
I've been using Redis wrong this whole time...
20:53
Dreams of Code
Рет қаралды 348 М.
Swift Fun Algorithms #2: Binary Search
15:16
Lets Build That App
Рет қаралды 29 М.
Sort, Filter, and Map data arrays in Swift | Continued Learning #13
28:36
Swiftful Thinking
Рет қаралды 20 М.
Custom Operators in Swift
22:50
Stewart Lynch
Рет қаралды 946
Generics: The most intimidating TypeScript feature
18:19
Matt Pocock
Рет қаралды 170 М.
Swift 3 Fun Algorithms: Recursive Search through Binary Tree
16:34
Lets Build That App
Рет қаралды 22 М.
25 Nooby Pandas Coding Mistakes You Should NEVER make.
11:30
Rob Mulla
Рет қаралды 265 М.
What it feels like cleaning up after a toddler.
00:40
Daniel LaBelle
Рет қаралды 91 МЛН