Wolfram: Iteration
Intro to Iteration in Wolfram language
Loop or iteration are usually done by many bultin functions.
Generate a list
Mapping a function to list
Map,MapIndexed,MapThread, etc.- Wolfram: Map Function to List
Recursion
Nest,NestWhile,Fold,FoldWhile,FixedPointetc.- Wolfram: Nest, FixedPoint (Recursion)
- Wolfram: Fold (reduce)
Filter
Select,Cases, etc.- Wolfram: List. Select (Filter)
Find membership
Position,MemberQ,Count, etc.- Wolfram: List. Check Exist, Count
- Wolfram: List. Position (Get Positions of Elements by Pattern)