Created
February 28, 2015 17:59
-
-
Save emergent/71e44036c41289777e6d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <stdio.h> | |
#import <Foundation/NSObject.h> | |
@interface HelloClass : NSObject | |
- (void) sayHello; | |
@end | |
@implementation HelloClass | |
- (void) sayHello { | |
printf("Hello Objective-C world!\n"); | |
} | |
@end | |
int main() { | |
id obj = [HelloClass alloc]; | |
[obj sayHello]; | |
return 0; | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment