Objective-C Overview

Objective-C is general-purpose language that is developed on top of C Programming language by adding features of Small Talk programming language making it an object-oriented language. It is primarily used in developing iOS and Mac OS X operating systems as well as its applications.

Initially, Objective-C was developed by NeXT for its NeXTSTEP OS from whom it was taken over by Apple for its iOS and Mac OS X.

Object-Oriented Programming

Objective-C fully supports object-oriented programming, including the four pillars of object-oriented development −

  • Encapsulation
  • Data hiding
  • Inheritance
  • Polymorphism

Example Code

#import <Foundation/Foundation.h>

void print () {
   NSLog (@"hello world");