Getting started with Android App Development

Introduction
Android App Development is a whole world of programming adventure, testing, learning and growth. It takes some time before you are proficient in developing great android applications but it takes a few hours to learn the basics from which you can advance. So its our aim in this tutorial to help you in getting started with Android App Development, using Android Studio and Java.
To develop android applications, one has to have prior experience in Java programming or using Kotlin programming language. Initially, android applications were created using Java (the native language used by Android) but then later in 2016, Kotlin was also developed for expressive, cleaner, simpler and faster to compile code. It supports a mix of both object oriented and functional programming. On the contrary, Java supports only object oriented programming, which simply means that every Java program must have a class for a successful compiling process.
To create and run your first android application, you will need to go through the following steps.
Step 1: Install Oracle Java Development Kit (JDK)
Since we are using Java for our development, we need a Java compiler, libraries and other components that are collectively bundled in what we call a Java Development Kit. For detailed instructions on how to install the Java Development Kit on your computer, click here. Make sure you install the JDK before you continue to step 2.
Step 2: Download and install Android Studio IDE
The next piece of software to install is called Android Studio. This is the official Integrated Development Environment (IDE) for developing Android applications. It comes with a text editor and gradle building capabilities. For detail instructions on how to install the IDE on your computer, go here. For more information on how to install Android Studio on other operating systems, check out Google’s installation instructions.
Step 3: Download and install USB Driver pack
To deploy and test your applications on a phone or tablet from your computer, download and install the following USB driver pack. If you computer, already has these drivers, make sure they are updated.
Step 4: Create a “Hello World” project
To make sure that every thing is running properly and for a fresher on creating android projects, create a simple project called “Hello World”. To do this, follow these simple steps.
- Launch Android Studio using its short cut icon. A welcome to Android Studio dialog shows up.

- Click Projects > New Project. This will open up a New Project window where you choose your starting project template depending on your needs.

- Choose Empty Activity and click Next.
- In the window that appears, Change the project name to Hello World, choose a location where you want to save your project and also set the development language to Java. By default, the create New Project Wizard selects for you the minimum Android SDK level on which your application will run based on statistics gathered from Google Play. We recommend to leave it as it is.

- Click Finish and Android Studio launches the main project window. To build your project successfully, Gradle should also be installed. This occurs automatically during the creation of your project. Just ensure your internet is on through out this process.

- Before you run your app, you need to have a device from which to view it. This can be your android smart phone or an Android Virtual Device (AVD). An AVD is simply an emulator that mimics the behavior of a real world android device.
Step 5: Run your app using an android phone
This is the option preferred by most developers since its fast, but if you have no smart phone you are left with only one option of testing your app using an AVD. This option is slow, consumes quite alot of RAM and it’s CPU intensive. To run your app, follow these simple steps;
- On your phone, enable Developer Options. To do this;
- Go to your Settings app
- Click on My Phone
- Look for the device Build number
- Click on it 7 times and then Android informs you that you are now a developer.
- Then go to your System settings > Developer Options > USB debugging
- Enable USB debugging.
- Now connect your phone to your computer using a USB cable. Android Studio, will now see your phone.
- Click the Run app button to launch your application. Give it some time for Gradle to build your app.
- A message appears on your phone to allow access for the app to display. Click allow and now you should be able to see your application on phone.
Step 6: Run your app using an Android Virtual Device (AVD)
Follow these steps to run your application using an AVD;
- If no AVD was created by default during installation of Android Studio, create one using these steps;
- Launch the AVD Manager (Device Manager) by selecting Tools > Device Manager or using the Device Manager button from the toolbar. An AVD window appears on the left of our screen.
- Click Create Device. A select Hardware dialog appears where you select the phone

- Select the device you want and click Next
- Select a system image or download it using the SDK manager

- Click Next
- Verify your AVD configuration and then click Finish.

- The created AVD should now appear in the Device Manager window
- In the Device Manager Window, first launch your AVD.

- Then, click the Run app button to launch your application. Give it some time for Gradle to build your app.
- You should now see your app running on your AVD device, that is if the process is successful.










