🌍 Android Development · subject
Android Development Java Programming Syllabus
The Java Programming syllabus for Android Development in full: 5 chapters, 22 topics and 78 sub-topics, every one listed below, plus 50 Java Programming flashcards with answers.
Java Programming syllabus: all 5 chapters
Expand any chapter to see its topics and sub-topics.
-
Introduction to Java
3 topics- History of Java
- Origins
- Evolution
- Java Versions
- Java Features
- Object-Oriented
- Platform Independent
- Simple and Secure
- Robust and Multithreaded
- High Performance
- Java Environment Setup
- Download and Install JDK
- Setting up IDE (Eclipse, IntelliJ, etc.)
- Configuring Environment Variables
- History of Java
-
Basic Syntax
5 topics- Hello World Program
- Structure of a Java Program
- Main Method
- Compiling and Running a Java Program
- Data Types
- Primitive Data Types
- Non-Primitive Data Types
- Variables
- Declaration and Initialization
- Scope of Variables
- Type Casting
- Operators
- Arithmetic Operators
- Relational Operators
- Logical Operators
- Assignment Operators
- Bitwise Operators
- Control Statements
- If-Else
- Switch
- Loops (For, While, Do-While)
- Hello World Program
-
Object-Oriented Programming
5 topics- Classes and Objects
- Class Definition
- Creating Objects
- Constructors
- this Keyword
- Inheritance
- Types of Inheritance
- super Keyword
- Method Overriding
- Polymorphism
- Compile-time Polymorphism
- Runtime Polymorphism
- Method Overloading
- Abstraction
- Abstract Classes
- Interfaces
- Encapsulation
- Access Modifiers
- Getters and Setters
- Classes and Objects
-
Advanced Java Concepts
6 topics- Exception Handling
- Try-Catch Block
- Finally Block
- Throw and Throws
- Custom Exceptions
- Collections Framework
- List
- Set
- Map
- Queue
- Iterator
- Generics
- Introduction to Generics
- Generic Classes
- Generic Methods
- Bounded Types
- Multithreading
- Thread Class
- Runnable Interface
- Synchronization
- Inter-thread Communication
- Thread Pool
- I/O Streams
- Byte Streams
- Character Streams
- Buffered Streams
- File Handling
- Lambda Expressions
- Syntax
- Functional Interfaces
- Method References
- Stream API
- Exception Handling
-
Java Development Tools
3 topics- Maven
- Introduction to Maven
- POM.xml
- Dependencies
- Build Lifecycle
- JUnit
- Writing Test Cases
- Annotations
- Assertions
- Test Suites
- Logging
- Log4j
- SLF4J
- Logging Levels
- Maven
Android Development Java Programming flashcards — 50 questions with answers
Who developed Java, in what year was it released, and what was its original name?
Java was developed by James Gosling at Sun Microsystems, released in 1995. Its original name was Oak (later renamed Java).
What was Java's original design slogan that captures its portability goal?
"Write Once, Run Anywhere" (WORA) — compiled Java bytecode runs on any platform with a JVM.
List at least six core features (buzzwords) of Java.
Simple, Object-Oriented, Platform-Independent, Secure, Robust, Multithreaded, Portable, High-Performance (via JIT), Distributed, and Dynamic.
Why is Java called platform-independent, and what makes it not fully so?
Java source compiles to platform-neutral bytecode that any JVM can run (platform-independent). However, the JVM itself is platform-dependent, so Java is "platform-independent at the language/bytecode level, platform-dependent at the JVM level."
What is the difference between JDK, JRE, and JVM?
JVM (Java Virtual Machine) executes bytecode. JRE (Java Runtime Environment) = JVM + core libraries needed to run programs. JDK (Java Development Kit) = JRE + development tools (compiler javac, debugger, etc.).
What is bytecode, and which file extension holds it?
Bytecode is the intermediate, platform-neutral instruction set produced by the Java compiler. It is stored in .class files and executed by the JVM.
What are the roles of the javac and java commands?
javac compiles .java source files into .class bytecode files. java launches the JVM to run a compiled .class file's main method.
Which environment variables are typically configured to set up Java, and what do they do?
JAVA_HOME points to the JDK installation directory. PATH is extended to include the JDK's bin folder so javac and java run from any terminal. (CLASSPATH optionally locates class/JAR files.)
Write a minimal Java "Hello World" program.
public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }
In the main method signature public static void main(String[] args), what does each keyword mean?
public = accessible by the JVM; static = callable without an object; void = returns nothing; main = entry-point name; String[] args = command-line arguments array.
What are the eight primitive data types in Java, with their sizes?
byte (8-bit), short (16-bit), int (32-bit), long (64-bit), float (32-bit), double (64-bit), char (16-bit Unicode), boolean (1 bit logically, true/false).
What is the range of the int primitive type in Java?
$-2^{31}$ to $2^{31}-1$, i.e. $-2{,}147{,}483{,}648$ to $2{,}147{,}483{,}647$.
What is the difference between a primitive type and a reference type in Java?
Primitives store the actual value directly (e.g. int, char). Reference types store a reference (address) to an object on the heap (e.g. String, arrays, class instances). Primitives cannot be null; references can.
What is autoboxing and unboxing in Java?
Autoboxing is automatic conversion of a primitive to its wrapper object (int → Integer). Unboxing is the reverse (Integer → int). It happens implicitly, e.g. Integer x = 5; int y = x;
What is the difference between a local variable, an instance variable, and a static variable?
Local: declared inside a method/block, no default value, scope limited to that block. Instance: declared in a class per-object, gets default values. Static: declared with static, shared across all instances of the class.
What default value is assigned to an uninitialized instance int, boolean, and object reference?
int defaults to 0, boolean defaults to false, and an object reference defaults to null.
What is the difference between the == operator and the .equals() method?
== compares references (whether two variables point to the same object) or primitive values. .equals() compares logical/content equality as defined by the class (e.g. String content).
List the categories of operators in Java.
Arithmetic (+ - * / %), Relational (< > <= >= == !=), Logical (&& || !), Bitwise (& | ^ ~ << >> >>>), Assignment (= += etc.), Unary (++ -- + - !), and Ternary (?:).
What is the difference between the >> and >>> operators in Java?
>> is the signed (arithmetic) right shift; it preserves the sign bit. >>> is the unsigned (logical) right shift; it fills the left with 0 regardless of sign.
Evaluate the difference between prefix (++i) and postfix (i++) increment.
++i increments first, then yields the new value. i++ yields the current value first, then increments. E.g. if $i=5$: $j = i{+}{+}$ gives $j=5$; $j = {+}{+}i$ gives $j=6$.
Show the other 30 Java Programming flashcards
What is the ternary conditional operator, and give its syntax?
A shorthand for if-else that returns a value: condition ? valueIfTrue : valueIfFalse. Example: int max = (a > b) ? a : b;
What is the difference between & and && (and between | and ||)?
& and | are non-short-circuit (always evaluate both operands, also work bitwise). && and || are short-circuit logical operators that skip the right operand when the result is already determined.
List the looping constructs available in Java.
for loop, enhanced for-each loop, while loop, and do-while loop (do-while executes the body at least once before checking the condition).
What is the difference between break and continue?
break terminates the entire loop (or switch) immediately. continue skips the rest of the current iteration and proceeds to the next iteration of the loop.
In a switch statement, what happens if you omit break, and what is the default clause?
Without break, execution "falls through" into subsequent case blocks. The default clause runs when no case matches (it is optional).
What is the difference between a class and an object in Java?
A class is a blueprint/template defining fields and methods. An object is a concrete instance of a class created at runtime with the new keyword, occupying memory.
What is a constructor, and how does it differ from a method?
A constructor initializes a new object; it has the same name as the class and no return type. Unlike methods, it is invoked automatically via new and cannot be called directly on an existing object.
What is the difference between constructor overloading and the default constructor?
Constructor overloading provides multiple constructors with different parameter lists. The default (no-arg) constructor is supplied automatically by the compiler only if no constructor is explicitly defined.
What does the this keyword refer to in Java?
this is a reference to the current object instance. It is used to disambiguate fields from parameters, invoke other constructors (this()), or pass the current object as an argument.
Define inheritance and give the keyword used to implement it in Java.
Inheritance lets a subclass acquire fields and methods of a superclass, enabling code reuse and an "is-a" relationship. It is implemented with the extends keyword (implements for interfaces).
Does Java support multiple inheritance of classes? How is the limitation addressed?
Java does not support multiple inheritance of classes (to avoid the Diamond Problem). A class can implement multiple interfaces, achieving multiple inheritance of type.
What is the role of the super keyword?
super refers to the immediate parent class. It is used to call the parent's constructor (super(...)), access parent fields, or invoke parent methods that a subclass has overridden.
Define polymorphism and its two types in Java.
Polymorphism means "many forms" — one interface, many implementations. Compile-time (static) polymorphism via method overloading; runtime (dynamic) polymorphism via method overriding.
What is the difference between method overloading and method overriding?
Overloading: same method name, different parameter lists, within the same class (compile-time). Overriding: subclass provides a new implementation of an inherited method with the same signature (runtime).
What are the rules for a valid method override in Java?
Same name, same parameter list, same or covariant return type; access modifier not more restrictive; cannot override final/static/private methods; checked exceptions thrown cannot be broader. Use @Override to enforce.
Define abstraction and the two ways Java achieves it.
Abstraction hides implementation details and exposes only essential features. Java achieves it via abstract classes (0–100% abstraction) and interfaces (traditionally 100% abstraction).
What is an abstract class and can it be instantiated?
An abstract class (declared with abstract) can contain both abstract methods (no body) and concrete methods. It cannot be instantiated directly; it must be subclassed and its abstract methods implemented.
What is the difference between an abstract class and an interface (Java 8+)?
Abstract class: single inheritance, can have constructors, instance fields, and any access modifiers. Interface: multiple inheritance of type, fields are public static final, methods are public abstract by default (plus default/static/private methods since Java 8/9).
Define encapsulation and how it is implemented in Java.
Encapsulation bundles data (fields) and methods together and restricts direct access. It is implemented by declaring fields private and exposing controlled access through public getter and setter methods.
What is the difference between a checked and an unchecked exception?
Checked exceptions are checked at compile time and must be handled or declared (e.g. IOException). Unchecked exceptions (RuntimeException subclasses like NullPointerException) occur at runtime and are not enforced by the compiler.
Describe the try-catch-finally structure and the purpose of finally.
try holds code that may throw; catch handles specific exceptions; finally always executes (whether or not an exception occurred) and is used for cleanup like closing resources.
What is the difference between throw and throws?
throw is a statement used to actually raise an exception object (throw new IllegalArgumentException()). throws is a clause in a method signature declaring which checked exceptions the method may propagate.
What is the root of the Java exception hierarchy, and its two main branches?
The root is java.lang.Throwable. Its two branches are Error (serious, unrecoverable JVM problems) and Exception (application-level, recoverable conditions).
What is the Java Collections Framework and its core root interfaces?
A unified architecture of interfaces and classes for storing/manipulating groups of objects. Core interfaces: Collection (root), with subinterfaces List, Set, and Queue; plus Map (a separate hierarchy).
Compare ArrayList and LinkedList.
ArrayList uses a dynamic array: fast random access $O(1)$, slow mid-list insert/delete $O(n)$. LinkedList uses a doubly linked list: fast insert/delete at ends $O(1)$, slow random access $O(n)$.
What is the difference between a List, a Set, and a Map?
List: ordered, allows duplicates, indexed. Set: no duplicates, typically unordered. Map: stores key–value pairs with unique keys (not a Collection subtype).
What are Generics in Java and what problem do they solve?
Generics enable parameterized types (e.g. List<String>), providing compile-time type safety and eliminating explicit casts. They catch type errors at compile time rather than as runtime ClassCastExceptions.
What are the possible states in the Java thread life cycle?
New, Runnable, Running, Blocked/Waiting (including Timed Waiting), and Terminated (Dead).
What are the two ways to create a thread in Java, and which is preferred?
1) Extend the Thread class and override run(). 2) Implement the Runnable interface and pass it to a Thread. Implementing Runnable is preferred because it leaves the class free to extend another class.
What is the difference between byte streams and character streams in Java I/O, and name a base class of each?
Byte streams handle raw 8-bit binary data (base classes InputStream/OutputStream, e.g. FileInputStream). Character streams handle 16-bit Unicode text (base classes Reader/Writer, e.g. FileReader). Character streams handle encoding for text.
Android Development Java Programming FAQ
What is in the Android Development Java Programming syllabus?
Android Development Java Programming is split into 5 chapters: Introduction to Java, Basic Syntax, Object-Oriented Programming, Advanced Java Concepts and Java Development Tools. Together they contain 22 topics and 78 sub-topics.
How many chapters are in Android Development Java Programming?
5 chapters, containing 22 topics and 78 sub-topics. The largest chapter is Advanced Java Concepts, with 6 topics.
Are there flashcards for Android Development Java Programming?
Yes — a 50-card Java Programming deck, printed in full in the flashcards section of this page and available in the Examius app with spaced repetition. The free plan covers one exam of your choice, including its flashcards; Examius Pro, a one-time purchase, unlocks every other exam and deck.