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 trialAndrew Jackson
Courses Plus Student 1,266 PointsIs it %d or %@ ?
I was having a problem with this question and found a forum posts with help documenting how to answer using %d when my version clearly asks me for %@.
Has the question been updated? because my answer of:
NSNumber *foxtrot = @24;
NSLog(@" %@", foxtrot);
1 Answer
Stone Preston
42,016 PointsNSNumbers are objects, so you need to use %@ which is the format specifier for objects. %d is only used for ints.
The reason you arent passing is your string is incorrect. It needs to output this: foxtrot 24
currently all you are outputting is 24