1. generics: meaning that they are independt of the type of thing you want to store inside these collections
2. optional
var checklistToEdit: Checklist?
3. Binding/ unwrapping: you cannot use optional variable directly, you must always test whether it has a value or not.
if let checklist = checklistToEdit { // “checklist” now contains the real object } else { // the optional was nil }
sfafads
时间: 2024-12-28 09:37:46