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) Types Printing Results

Output won't show up on assistant editor.

I'm trying to follow along with the video describing about using "print function" and using the assistant editor, but when I do the same thing on my xcode, nothing shows up on the assistant editor part of my screen.

3 Answers

I believe it has to do with newer versions of XCode and swift. I also cannot see output in the console, not with this particular code anyway - and note that println is now print (which already adds a newline escape character).

It really can be anything. I just can't get an output to show up. Here's a super basic with nothing showing up in the assistant editor output. Is there a way I can post a screenshot?

var animal = "cow" print(animal)

You can see output if you enable "view debugging area"

Zaq Dayton
Zaq Dayton
2,244 Points

If this isn't too late, there are three buttons in the top-right corner of the xcode window (box with bar on left, on right, and at the bottom). If you click one of those, you will see what you print there. I think it is similar to JS and the browser's console. If you "print" something in JS, it's not going to show up in the console unless you use the console.log function. Printing anything will only be printed to the actual webpage.