Skip to content
beginner Phase 2 · Android Fundamentals

What is Android?

Understand Android's architecture, version history, and its place in the mobile ecosystem.

30m
0 problems
Topic Progress 0%

What is Android?

What is Android?

Android is an open-source, Linux-based operating system designed primarily for touchscreen mobile devices such as smartphones and tablets. Google leads the Android Open Source Project (AOSP), and it powers over 3 billion active devices worldwide.

Android Architecture

Android uses a layered architecture built on top of the Linux kernel:

┌─────────────────────────────────┐
│         Applications            │
├─────────────────────────────────┤
│      Application Framework      │
├─────────────────────────────────┤
│  Native Libraries │ Android Runtime │
├─────────────────────────────────┤
│      Hardware Abstraction Layer  │
├─────────────────────────────────┤
│         Linux Kernel            │
└─────────────────────────────────┘

Linux Kernel provides core system services: memory management, process scheduling, device drivers, and security. Android does not use the GNU C Library (glibc) — it uses Bionic, a lightweight C library optimized for embedded devices.

Hardware Abstraction Layer (HAL) defines interfaces that hardware vendors implement, allowing the framework to access hardware without knowing implementation details.

Native Libraries include surface manager, media framework, SQLite, OpenGL ES, and libc. These are written in C/C++ and compiled for the target architecture.

Android Runtime (ART) executes DEX bytecode. ART replaced the Dalvik VM in Android 5.0. It uses ahead-of-time (AOT) compilation, improving app startup time and runtime performance.

Application Framework provides building blocks: Activity Manager, Window Manager, Content Providers, View System, Package Manager, and Notification Manager.

Android Versions

Android releases follow an alphabetical dessert naming convention (historically) and are identified by API level:

Version Name API Level Year
13 Tiramisu 33 2022
14 Upside Down Cake 34 2023
15 Vanilla Ice Cream 35 2024
16 Baklava 36 2025

Each API level introduces new capabilities. You set minSdkVersion in Gradle to define the oldest Android version your app supports, and targetSdkVersion to declare the API level your app is designed for.

// build.gradle.kts
android {
    defaultConfig {
        minSdk = 24      // Android 7.0 Nougat minimum
        targetSdk = 35    // Designed for Android 15
        compileSdk = 35    // Compiled against Android 15 SDK
    }
}

The Android Ecosystem

Google Play Store is the primary distribution channel with over 2.7 million apps. Apps are distributed as Android Package (APK) files, now replaced by Android App Bundle (AAB) for new submissions.

Third-party stores include Samsung Galaxy Store, Amazon Appstore, and F-Droid (open-source). Some markets in China use alternative stores like Tencent MyApp.

Android Go is a lightweight version of Android for low-RAM devices (under 2GB), with optimized system apps and a curated Play Store.

Native vs Cross-Platform Development

Native Development uses Kotlin or Java with Android SDK. You get full platform access, best performance, and native UI components. This is the standard for professional Android development.

Cross-Platform Frameworks like Flutter (Dart), React Native (JavaScript), and Kotlin Multiplatform let you share code across platforms. They trade some platform integration for code reuse.

For Amazon SDE interviews, native Android knowledge is expected. Understanding the framework internals — Activity lifecycle, Context, IPC mechanisms — separates strong candidates from those who only know the API surface.

Development Environment

Development Environment

Android Studio

Android Studio is the official IDE built on IntelliJ IDEA. It includes:

  • Layout Editor: Visual drag-and-drop UI design with ConstraintLayout support
  • APK Analyzer: Inspect your APK structure, method count, and resource usage
  • Database Inspector: Query SQLite databases and Room tables at runtime
  • Profiler: CPU, memory, network, and energy usage monitoring
  • Lint: Static analysis for correctness, security, and performance

Build System

Android uses Gradle as its build system. The build process compiles resources, generates R.java, compiles Kotlin/Java to DEX bytecode, and packages everything into an APK or AAB.

// Project-level build.gradle.kts
plugins {
    id("com.android.application") version "8.2.0" apply false
    id("org.jetbrains.kotlin.android") version "1.9.20" apply false
}

// Module-level build.gradle.kts
plugins {
    id("com.android.application")
    id("org.jetbrains.kotlin.android")
}

android {
    namespace = "com.example.myapp"
    compileSdk = 35

    defaultConfig {
        applicationId = "com.example.myapp"
        minSdk = 24
        targetSdk = 35
        versionCode = 1
        versionName = "1.0"
    }

    buildTypes {
        release {
            isMinifyEnabled = true
            proguardFiles(
                getDefaultProguardFile("proguard-android-optimize.txt"),
                "proguard-rules.pro"
            )
        }
    }

    compileOptions {
        sourceCompatibility = JavaVersion.VERSION_17
        targetCompatibility = JavaVersion.VERSION_17
    }

    kotlinOptions {
        jvmTarget = "17"
    }
}

Gradle Sync

When you modify build.gradle, Android Studio performs a Gradle Sync — it resolves dependencies, generates BuildConfig, and validates the configuration. If sync fails, check your internet connection, SDK paths, and plugin versions.

Emulator and Device Testing

The Android Emulator simulates real devices with different screen sizes, Android versions, and hardware configurations. For performance testing, always test on physical devices — emulators use host CPU and don't accurately represent thermal throttling, battery drain, or memory pressure.

Version Control

Android projects use Git. The .gitignore should exclude:

  • /.gradle/ — Gradle cache
  • /.idea/ — IDE settings
  • /build/ — Generated files
  • local.properties — SDK path (machine-specific)
  • *.apk, *.aab — Built artifacts

Quiz

1. Which runtime replaced Dalvik in Android 5.0?

Question 1 options

2. What is the Android Open Source Project (AOSP)?

Question 2 options

3. What is the primary build system for Android projects?

Question 3 options

4. What is the purpose of minSdkVersion?

Question 4 options

Flashcards

Question

What does ART stand for and what replaced?

Answer

Android Runtime — it replaced the Dalvik VM starting in Android 5.0 Lollipop. ART uses AOT compilation instead of JIT.

Question

What is the difference between minSdkVersion, targetSdkVersion, and compileSdkVersion?

Answer

minSdk = oldest supported version; targetSdk = version your app is designed for; compileSdk = version you compile against (determines available APIs).

Question

Why does Android use Bionic instead of glibc?

Answer

Bionic is a lightweight C library optimized for mobile devices — smaller binary size, faster startup, and BSD-licensed (avoiding GPL complications).

Question

What is an Android App Bundle (AAB)?

Answer

A publishing format that includes all app resources and configurations, letting Google Play generate optimized APKs for each device configuration.

Revision Notes

Key Takeaways

  • 1. Android uses a layered architecture built on the Linux kernel with Bionic C library
  • 2. ART replaced Dalvik in Android 5.0, using AOT compilation for better performance
  • 3. minSdkVersion determines device compatibility; targetSdkVersion affects runtime behavior
  • 4. Android App Bundle (AAB) is now required for Play Store submissions
  • 5. Kotlin is the preferred language for modern Android development

Interview Tips

  • Be able to explain the Android architecture layers and what each provides
  • Know the difference between APK and AAB formats
  • Understand why Google chose Bionic over glibc for the C library
  • Be ready to discuss Android version compatibility and API level implications

Cheat Sheet

What is Android? Cheat Sheet

Architecture (bottom to top):

  • Linux Kernel → HAL → Native Libraries → Android Runtime → Application Framework → Apps

Key Versions:

  • Android 5.0 (API 21): ART replaces Dalvik
  • Android 8.0 (API 26): Background execution limits
  • Android 10 (API 29): Scoped storage
  • Android 13 (API 33): Per-app language preferences

Build Config:

  • minSdk: oldest supported version
  • targetSdk: designed-for version
  • compileSdk: compilation target

Tools:

  • Android Studio (IDE)
  • Gradle (build system)
  • ADB (debugging)
  • Emulator (testing)