I watched Swift Talk episode 32, View Models at Kickstarter. The video demonstrates how to create View Model. The View Model is very well defined. Simple example, and very clear explanation!
The following is my note for it.
- Use startIndex and endIndex.
ArraySliceis not guaranteed that it starts from index 0.
stride()function requires that index is integer type, meaning type should be
Collectionprotocol doesn’t have
Collection’s subscript return