How to Start iOS Development – Part 1

Introduction to starting development on the iOS framework

Prerequisites to starting development

Tools required

A Mac, Mac mini or a Mac book is required.

You need a Mac, MacBook or the cheapest available option which is the Mac mini with the latest OS X running on it. Any of the above with minimum requirements is needed to run iOS development tools like Xcode. Xcode is the IDE or the Integrated Development Environment (IDE) that contains a collection of tools is required to develop and create applications for the macOS, iOS, WatchOS and tvOS.

Part of the Xcode suite is Simulator which is an Xcode tool that runs on the Mac and allows a developer to test the prototypes of his application without an actual Apple phone.

There is a third method which enables you to work on Xcode without having access to a Mac which entails using something called a ‘Virtual Machine’. Virtual Machines are mostly run using a software called VMWare that you would have to purchase and install on your Windows or Linux based PC. Using VMWare you can then setup a simulation of a Mac and use it to run Xcode. However, this is not a recommended method as virtual machines lack the robustness that an actual machine would.

Steps to follow

Download and install Xcode from the Apple’s developer website and sign up freely to be able to download Xcode.

iOSSkip this step if you have already managed to download Xcode, if not then go to Apple’s developer website and sign in or sign up free to be able to download Xcode.

Download latest version of Xcode available on the page loaded. Once the download is completed, follow the instructions that are mentioned to install it on your system.

Programming Background

Languages used for writing software for the iOS and OS X are object oriented programming languages. If most of your experience is in using a non-object oriented language such as C, jumping directly to iOS development will be tough.

It is recommended to learn object oriented languages like C++ or Java before diving into iOS development. Although it is recommended but it is certainly not mandatory, instead you will have to put in a certain amount of extra effort when learning iOS development in this case.

iOS is MVC( Model-View-Controller) based and it is important for you to get some understanding of MVC pattern before starting.

Also, a database is an important part of many apps and it is very much likely that you will also be developing app that needs to store data locally. Considering that, you should have basic database concepts to understand local data storage.

Finally the most important aspect is that you must possess a love and craze for programming. This love will drive you to master the concepts of iOS development.

Language to Start With

Objective C / Swift

iOS development was born with Objective C as its primary development language. The language was the exclusive platform that was required to build native iOS applications which had its own pros and cons.

Lately however, Apple has introduced a new language named Swift for this purpose. Since then people tend to choose between Objective C and Swift to get started with learning iOS development.

To make a choice between the two consider the following points to assist in making in a decision:

  • As people say “Old is gold”, this is also true for Objective C. Objective C has existed for a long time and has gained stability over this period.
  • On the other hand even though Swift is rapidly evolving the compiler is not mature yet. What bothers me personally is that with almost every new revision of Swift, there are some major changes that I have to deal with myself while updating my Swift based project.
  • A large number of very useful frameworks are Objective C based and have not been translated to Swift yet.
  • There is big community support as for Objective C not so much for Swift as people are still learning it.
  • Objective C syntax may appear weird to newbies. On the other hand, you get familiarized with Swift syntax more easily.
  • From what I have understood, Swift is designed to be more safe, modern and powerful.
  • Swift is faster, requires less code, and supports dynamic libraries and if allowed to go into more technical details, it can be said that Swift has an edge over Objective C.

In my personal opinion, you can start with Swift but if you want to be a good iOS developer you should first know Objective-C properly. In the end it doesn’t matter what you learn first, eventually you will gain command over both languages.

Write a Hello World Program

Locate Xcode from the launchpad and click on the icon to start it up.


From the welcome dialog, choose “Create a new Xcode project”.


Choose the “Single View Application” from the given templates list and click the “Next” in bottom right corner.


This brings up following screen.


Product Name: This the name of your project and also your app (You can always change name of your app later on from the plist file)

Language: Choose a language for the project, Swift or Objective-C whatever you are comfortable with. For this tutorial, I am choosing Swift.

Devices: Choose Universal to make your app compatible with the iPhone and iPad devices.

Uncheck the option “User Core Data” as you don’t need core data in this simple project and press “Next”. It will ask you for the location in which to create the project, choose a location and press “Create”.

Open file “ViewController.swift” if your selected language was Swift and “ViewController.m” if it was Objective-C from Project Navigator as shown below:


Your view controller file will look different in syntax than shown above if you have chosen the Objective-C language for your project.

Insert the following function after closing the curly bracket of function ‘viewDidLoad’.

Swift Code (For Swift language)

override func touchesBegan(touches: Set<UITouch>, withEvent event: UIEvent?) {

        let alert = UIAlertController(title: “Hello World!”, message:”Tap on screen was detected”, preferredStyle: .Alert)

        alert.addAction(UIAlertAction(title: “OK”, style: .Default) { _ in })

        self.presentViewController(alert, animated: true){}


After editing, your ViewController.swift file should look like this:


Objective-C Code ( For Objective-C language)

Add the following code to your .m file

-(void)touchesBegan:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event


    UIAlertController *alertController = [UIAlertController alertControllerWithTitle:@”Hello World!”

                                                                             message:@”Tap on screen was detected”


    //We add buttons to the alert controller by creating UIAlertActions:

    UIAlertAction *actionOk = [UIAlertAction actionWithTitle:@”Ok”


                                                     handler:nil]; //You can use a block here to handle a press on this button

    [alertController addAction:actionOk];

    [self presentViewController:alertController animated:YES completion:nil];



Your ViewController.m file should look like this after editing:


Build And Run

Now that you have made the necessary changes it is time to run the project and see the output. Simply press the play button on the top left corner of Xcode and it will run the project on the iOS Simulator.

Although you can also install the app you have made on an iOS device that is not within the scope of this tutorial.


The project should build successfully and a simulator will appear with the app installed on it with a plain white screen. Tap on the simulator screen and an alert will appear as below.


Congratulation! You’ve built your first iPhone app. Even though it’s a very simple app you have already developed a familiarity with Xcode and how an iOS app is developed.





No Comment

Leave a Reply



About us

We write the long boring posts that no one wants to read. Basically, we tell you why things are the way they are.



Sign Up for Our Newsletter

newsiteiconThe Lamp's biggest Theories on Politics, Culture, Geopolitics, History and Design delivered directly to your inbox.

Your email address will be used in accordance with our Privacy Policy.