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.