0% found this document useful (0 votes)
2 views2 pages

Java Fundamentals Part1

The document provides an overview of Java fundamentals, including its history, features, and components such as JDK, JRE, and JVM. It explains the programming process, Java's principle of Write Once, Run Anywhere, and outlines primitive data types. Additionally, it includes a visual timeline and interview questions related to Java concepts.

Uploaded by

Learn NewSkill
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views2 pages

Java Fundamentals Part1

The document provides an overview of Java fundamentals, including its history, features, and components such as JDK, JRE, and JVM. It explains the programming process, Java's principle of Write Once, Run Anywhere, and outlines primitive data types. Additionally, it includes a visual timeline and interview questions related to Java concepts.

Uploaded by

Learn NewSkill
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Java Fundamentals – Part 1

Learning Roadmap
Programming → Java → History → Founder → Features → Platform → JDK/JRE/JVM →
Compilation → Data Types

What is Programming?
Programming is the process of writing instructions that tell a computer what to do. Java
source code is compiled into bytecode and executed by the JVM.

What is Java?
Java is a high-level, object-oriented, class-based programming language created at Sun
Microsystems. Its famous principle is Write Once, Run Anywhere (WORA).

History
1991: Green Project started
James Gosling created Oak
1995: Renamed to Java and released
2010: Oracle acquired Sun Microsystems.

Visual Timeline
1991 ■■ Green Project

James Gosling creates Oak

1995 ■■ Java Released ■

2010 ■■ Oracle acquires Sun

JDK, JRE and JVM


JDK
■■■ javac (Compiler)
■■■ JRE
■ ■■■ JVM
■ ■■■ Libraries
■■■ Development Tools

Feature JDK JRE JVM

Develop ✔ ✘ ✘
Compile ✔ ✘ ✘
Run ✔ ✔ ✔
Contains JVM ✔ ✔ Self

Java Execution Flow


[Link]

javac

[Link] (Bytecode)

JVM

Machine Code

Output

Primitive Data Types


Type Size Example
byte 1 byte byte b=10;
short 2 bytes short s=100;
int 4 bytes int i=1000;
long 8 bytes long l=100L;
float 4 bytes float f=10.5f;
double 8 bytes double d=10.5;
char 2 bytes char c='A';
boolean true/false boolean ok=true;

Visual Classification
Data Types ■■■ Primitive ■ ■■■ byte ■ ■■■ short ■ ■■■ int ■ ■■■ long
■ ■■■ float ■ ■■■ double ■ ■■■ char ■ ■■■ boolean ■■■ Reference ■■■
String ■■■ Arrays ■■■ Objects ■■■ Classes

Interview Questions
1. What is Java?

2. Why is Java platform independent?

3. Differentiate JDK, JRE and JVM.

4. What is bytecode?

5. List all primitive data types.

6. Explain type casting.

You might also like