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 Basics (retired) Control Flow If Statement

Keith Galway
PLUS
Keith Galway
Courses Plus Student 701 Points

A couple of issues

Firstly, my console output isnt working, I am running Xcode 7.1, i go to view > assistant editor > show assistant editor and the extra assistant pane appears but the console output like seen in the video tutorials when a println statement is written does not appear. And secondly, println() isn't working anymore, Xcode advises me to just use print(). When I write println() the an error occurs that instructs me to replace 'println' to 'print'.

Charlie Todd
Charlie Todd
796 Points

Hi Keith.

I was recently stumped by this too. The answer is simple though, whilst Amit has made and recorded these lessons using Xcode 6 (or previous, I'm not able to tell, personally) - as you and I are using Xcode 7 there are two major differences I've seen between what we're told and what we experience.

1) println() is no longer valid to use for a new line. Xcode 7 operates print() to automatically put a new line in, and instead you have tell print() when you DON'T want to have a line break, using print(//string etc here// , appendNewLine: False)

2) The console output now lives within the debug area, rather than the assistant editor from what I can tell. To access this (and see your output as Amit does in his tutorials), press "Shift + Command + Y". You can also access it via View -> Debug Area -> Show Debug Area.

Hope this helps!

Charlie