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 trialCullen O'Brien
174 PointsHow is this not working? let name = "Cullen" let greeting = "\("Hi there"), \(name)"
I don't understand how this does not work.
// Enter your code below
let name = "Cullen"
let greeting = "\("Hi there"), \(name)"
1 Answer
Steven Deutsch
21,046 PointsHey there Cullen,
You're so close! We just need to make a small tweak in your code. You don't need to use String Interpolation on the "Hi there," section of the string because it is a string literal. You only use string interpolation when you want to place the value associated with a particular variable or constant inside of a string.
// Enter your code below
let name = "Cullen"
// It should look like this
let greeting = "Hi there, \(name)"
Good Luck!
Cullen O'Brien
174 PointsCullen O'Brien
174 PointsThanks Steve, that worked. I appreciate it!