I am new to Obejctive-C as well as Mac. I have been trying to learn online and have written this simple piece of code , but the `NSLog` doesn't work for me.

```
#import <Foundation/Foundation.h>

@interface Person : NSObject{
    int age ;
    int weight;
}

-(void) print;
-(void) setAge:(int) a;
-(void) setWeight:(int) w;

@end
//---implementation---
@implementation Person

-(void) print{
    NSLog(@"I am %i years and my weight is %i",age,weight);
 }

-(void) setAge:(int) a{
    age = a;
}

-(void) setWeight:(int) w{
    weight = w;
}
@end

int main(int argc, char *argV[]){

    Person *test;
    test = [test init];
    [test setAge:25];
    [test setWeight:75];
    [test print];
    return 0;
}

```

![enter image description here](https://i.stack.imgur.com/kmZAB.jpg)

When I run the program the output console disappears as shown in the top right hand corner. When I display the output console by explicitly clicking on the same, I can see the program exited with code 0(successful output?) but `NSLog` not printed.

![enter image description here](https://i.stack.imgur.com/iWaMt.png)

Let me know if I am doing some rookie mistake :)