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 trialanis ahmed
194 Pointsi dont uderstand
help
let language = "Swift"
println(language)
1 Answer
Jhoan Arango
14,575 PointsHello
Welcome to the beautiful world of coding, it might be a bit hard to understand at first, but as you go I promise you will understand more and you’ll like it even more.
In your question you say you don’t understand, but what part ? the printing part or the assigning a value to a variable ? I’ll explain both anyways.
In swift when you want to apply a value to a variable you have to use the equal sign =.
So it should look something like this
var anyName = “value”
if you want to “print” or show the value that’s within the variable, in this case “value”, you use the method “println()”
println(anyName) // it will print “value”
hope it helps a bit.