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

Cesar Romero
Cesar Romero
169 Points

Incorrect Answer on println challenge question

I keep trying this code for the println question and the answers say that this is correct. I would like peoples inputs on what they would write for the code and what could be a potential answer to the question, im stuck as of right now

println.swift
let language = "Swift"
println = ("Learn \(language)")

2 Answers

Holger Liesegang
Holger Liesegang
50,595 Points

Welcome to Treehouse, Cesar!

you might want to print the string: "Learning Swift" like so:

let language = "Swift"
println("Learning \(language)")

***Changed println ("Learning \(language)") to println("Learning \(language)") as Daniel Botta correctly mentioned ... looks nicer this way :)

Daniel Botta
Daniel Botta
17,956 Points

with the above answer, I believe that it is correct although you may need to remove the space between println and the (). Println is a Swift built in function, so you don't set image println portion of the statement equal to anything.