Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialThomas Hoffmann
903 PointsStuck at first task of Collections and Control Flow
I believe I understand what they are asking from me for the first part, but I m not sure what exactly I have to equal the multiplier to.
var results: [Int] = [6]
for number in 1...10{
print("\(number) times 6 is equal to \(number * 6)")
}
let mutliplier = 1...10
3 Answers
Jennifer Nordell
Treehouse TeacherI think maybe you've gotten some things mixed up in their instructions. I posted the solution to this challenge along with an explanation here: https://teamtreehouse.com/community/how-do-i-add-the-for-in-loop-to-the-variable-results
Take a look and see if it clarifies what they're asking you to do and how to solve it. Hope it helps!
Thomas Hoffmann
903 PointsThanks for the answer, in that case using print simply means that we "print" the values in our debug window for us to see?
Jennifer Nordell
Treehouse TeacherRight, it'll print to the console. And in challenges it's important to not do things they don't ask you to do. I've seen perfectly good code break a challenge because it was printed instead of returned or vice versa. They are super picky! :)
Thomas Hoffmann
903 PointsAh ok thanks a lot!