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 trial

iOS Swift 2.0 Collections and Control Flow Control Flow With Conditional Statements FizzBuzz

Markus Flodmark
Markus Flodmark
8,083 Points

Incorrect number

Hi, just want to tell you that you said that we should divide it by 6 in the video before the challenge but 3 in the solution. 6 didn't work but 3 did. Weird.

1 Answer

Jennifer Nordell
seal-mask
STAFF
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

Hi there! I think you misunderstood what Pasan said. On the screen at 0:18 they show a "6". And that part, you have correct. But what is said is this:

"Given a random number, if the number is divisible by 3,then you print out the string Fizz, exactly like I've shown you.

Because 6 is evenly divisible by 3 then "Fizz" is displayed, which is what they are trying to illustrate with this small animation.

Happy coding! :sparkles: