Post by SAS Web Nepal.
Thursday, July 24, 2014
Saturday, July 5, 2014
Lesson-1, Hello World Program
What you need?
- A MAC OR PC running XCODE
- GCC compiler installed
First Hello World Program
#import <Foundation/Foundation.h> int main (int argc, const char *argv[])
{
NSLog (@"Hello, Objective-C!");
return (0);
} // main
How to Run the program?
- Save the program using Command + S
- Run the program using Command + R
That is simply means, we are telling that compiler we are using the Foundation Framework, which is collection of parts headers, images, libraries etc.
NSLog (@"Hello, Objective-C!");
NSLog is a statement that is used to display string on the screen like pritnf() in C programming.
Subscribe to:
Posts (Atom)