iOS Swift Collections and Control Flow Control Flow With Loops For In Loops

Not sure how to append to results

Not sure how to append.

loops.swift
// Enter your code below
var results: [Int] = []

for multiplier in 1...10 {
  print("\(multiplier) * 6")
}

multiplier.append("results")

1 Answer

KRIS NIKOLAISEN
PRO
KRIS NIKOLAISEN
Pro Student 50,888 Points

Some hints:

  • You won't be printing anything
  • You will use append but this should be done with the results array: results.append()
  • You should append inside the loop