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 Build a Simple iPhone App with Objective-C Getting Started With Xcode Objective-C Recap

Where do you add this NSString? The teacher just writes it out but does not tell you where this line of code goes.

I am in the start to iOS fun facts but don't know where the teacher wants this first string of code to go

There is no visual aid to tell me where does this first line of code is suppose to go, so Im a little lost. I understand the reason for the code, just don't know where its suppose to go.

1 Answer

You don't have to write it somewhere. However, if you want to, you can do it and check the result at ViewController.m:

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.

    NSString *myString = @"Fun Facts";
    NSLog(@"%@", myString);

}

Run and check the result in Debug Area.