View Single Post
iMarco

 
Member Since: May 17, 2008
Posts: 21
iMarco is on a distinguished road

iMarco is offline
Edit: The "Object-C" was a typo, sorry...objective

Hello guys, I just got this great book (Programming in Objective-C 2.0) and I'm already working on the typical "hello world" program. I typed in the code, debugging ended normally on Xcode but I didn't get anything on screen. Here's the code:

#import <Foundation/Foundation.h>

int main (int argc, const char * argv[]) {
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];

// insert code here...
NSLog(@"Hello World");
NSLog(@"Hello World 2");
[pool drain];
return 0;
}

I pressed Build and Go and I got nothing. Was I supposed to get something on the terminal or anything?? Thanks!
QUOTE Thanks