Foundation

Array

// subarray
cards[0..<cardsCount]
cards.count
cards.indices // 0..<card.count
cards.append(item)

String

"😀"
"Hello \(name)!"

Protocol: Identifiable

struct Card: Identifiable {
  var id: Int
}

let cardsList = [Card(id: 1), Card(id: 2)]

ForEach(cardsList) { card in
  // ...
}

Protocol: Equatable