SlideShare a Scribd company logo
Presentation By:-
Ajeet Kumar Verma
B.C.A 3rd
yr
PROGRAMMING IN JAVA
Introduction to JAVA
Topic:-Genesis and overview of
Java
Contents
• What is JAVA?
● • What is OOPs?
● • Why Java?
● Characteristics of JAVA
● Overview of Java.
● The difference between Java and C++?
● A Simple JAVA Program
What is JAVA?
● Developed by Sun Microsystems (James Gosling)
● A general-purpose Object-Oriented language
● Based on C/C++
● Designed for easy Web/Internet applications
● Widespread acceptance
What is Object Oriented
Programming?
● Object-oriented programming is a method of
implementation in which programs are organized as
cooperative collections of objects, each of which
represents an instance of some class, and whose
classes are all members of one or more hierarchy of
classes united via inheritance relationships.
Principles of OOP
● All object-oriented programming languages provide
mechanisms that help you implement the
objectoriented model.
• They are:--
● Encapsulation
● Inheritance
● Polymorphism
Data Encapsulation
● Encapsulation is the mechanism that binds together
code and the data it manipulates, and keeps both safe
from outside interference and misuse.
● Example:-
class Account {
int x=10;
float withdraw();
void deposit(float amount);
float balance;
}
Advantages of Encapsulation
● Protection
● Consistency
● Allows change
Inheritance
● Inheritance is the process by which one object acquires the
properties of another object.
● A class that is derived from another class is called a subclass
(also a derived class, extended class, or child class).
● The class from which the subclass is derived is called a super
class (also a base class or a parent class).
● A class which is a subtype of a more general class is said to
be inherited from it.
Inheritance cont’d
● The sub-class inherits the base class’ data members
and member functions.
● A sub-class has all data members of its base-class
plus its own.
● A sub-class has all member functions of its base
class (with changes) plus its own.
Polymorphism
● Polymorphism refers to a programming language's ability to process
objects differently depending on their data type or class.
● Generally, the ability to appear in many forms.
● More specifically, it is the ability to redefine methods for derived
classes.
● For example, given a base class shape, polymorphism enables the
programmer to define different area methods for any number of derived
classes, such as circles, rectangles and triangles. No matter what shape
an object is, applying the area method to it will return the correct results.
Why Java?
● Java is the Internet programming language.
● Java enables users to develop and deploy
applications on the Internet for servers, desktop
computers, and small hand-held devices.
Characteristics of Java
● Java Is Simple
● Java Is Object-Oriented
● Java Is Distributed
● Java Is Interpreted
● Java Is Robust
● Java Is Secure
● Java Is Architecture-Neutral
● Java Is Portable
● Java's Performance
● Java Is Multithreaded
● Java Is Dynamic
JDK Versions
● JDK 1.02 (1995) … 250 classes
● JDK 1.1 (1996) … 500 classes
● JDK 1.2 (1998) … 2300 classes
● JDK 1.3 (2000) … 2300 classes
● JDK 1.4 (2002) … 2300 classes
● JDK 1.5 (2004) … 3500 classes
● JDK 1.6 (2006) … 3500 classes
● JDK 1.7 (2011) … 3500 classes
A Simple Java Program
● //This program prints Welcome to Java!
public class Welcome
{
public static void main(String[] args)
{
System.out.println("Welcome to Java!");
{
{
Ad

More Related Content

What's hot (20)

Introduction to Java -unit-1
Introduction to Java -unit-1Introduction to Java -unit-1
Introduction to Java -unit-1
RubaNagarajan
 
Introduction to Java Programming
Introduction to Java ProgrammingIntroduction to Java Programming
Introduction to Java Programming
Ravi Kant Sahu
 
Introduction to java
Introduction to java Introduction to java
Introduction to java
Java Lover
 
Genesis and Overview of Java
Genesis and Overview of Java Genesis and Overview of Java
Genesis and Overview of Java
Ravi_Kant_Sahu
 
Introduction to java (revised)
Introduction to java (revised)Introduction to java (revised)
Introduction to java (revised)
Sujit Majety
 
JRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVAJRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVA
Mehak Tawakley
 
Basics of JAVA programming
Basics of JAVA programmingBasics of JAVA programming
Basics of JAVA programming
Elizabeth Thomas
 
Java features
Java featuresJava features
Java features
Prashant Gajendra
 
Introduction to basics of java
Introduction to basics of javaIntroduction to basics of java
Introduction to basics of java
vinay arora
 
Introduction to Java
Introduction to JavaIntroduction to Java
Introduction to Java
Professional Guru
 
Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...
Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...
Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...
Edureka!
 
Core Java
Core JavaCore Java
Core Java
NA
 
Training on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan SanidhyaTraining on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan Sanidhya
Shravan Sanidhya
 
Learn Java with Dr. Rifat Shahriyar
Learn Java with Dr. Rifat ShahriyarLearn Java with Dr. Rifat Shahriyar
Learn Java with Dr. Rifat Shahriyar
Abir Mohammad
 
Java Programming
Java ProgrammingJava Programming
Java Programming
Elizabeth alexander
 
Core java slides
Core java slidesCore java slides
Core java slides
Abhilash Nair
 
Presentation on Core java
Presentation on Core javaPresentation on Core java
Presentation on Core java
mahir jain
 
Introduction to JAVA
Introduction to JAVAIntroduction to JAVA
Introduction to JAVA
ParminderKundu
 
Introduction to Java Programming, Basic Structure, variables Data type, input...
Introduction to Java Programming, Basic Structure, variables Data type, input...Introduction to Java Programming, Basic Structure, variables Data type, input...
Introduction to Java Programming, Basic Structure, variables Data type, input...
Mr. Akaash
 
Basic concept of OOP's
Basic concept of OOP'sBasic concept of OOP's
Basic concept of OOP's
Prof. Dr. K. Adisesha
 
Introduction to Java -unit-1
Introduction to Java -unit-1Introduction to Java -unit-1
Introduction to Java -unit-1
RubaNagarajan
 
Introduction to Java Programming
Introduction to Java ProgrammingIntroduction to Java Programming
Introduction to Java Programming
Ravi Kant Sahu
 
Introduction to java
Introduction to java Introduction to java
Introduction to java
Java Lover
 
Genesis and Overview of Java
Genesis and Overview of Java Genesis and Overview of Java
Genesis and Overview of Java
Ravi_Kant_Sahu
 
Introduction to java (revised)
Introduction to java (revised)Introduction to java (revised)
Introduction to java (revised)
Sujit Majety
 
JRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVAJRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVA
Mehak Tawakley
 
Basics of JAVA programming
Basics of JAVA programmingBasics of JAVA programming
Basics of JAVA programming
Elizabeth Thomas
 
Introduction to basics of java
Introduction to basics of javaIntroduction to basics of java
Introduction to basics of java
vinay arora
 
Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...
Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...
Java Tutorial | Java Programming Tutorial | Java Basics | Java Training | Edu...
Edureka!
 
Core Java
Core JavaCore Java
Core Java
NA
 
Training on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan SanidhyaTraining on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan Sanidhya
Shravan Sanidhya
 
Learn Java with Dr. Rifat Shahriyar
Learn Java with Dr. Rifat ShahriyarLearn Java with Dr. Rifat Shahriyar
Learn Java with Dr. Rifat Shahriyar
Abir Mohammad
 
Presentation on Core java
Presentation on Core javaPresentation on Core java
Presentation on Core java
mahir jain
 
Introduction to Java Programming, Basic Structure, variables Data type, input...
Introduction to Java Programming, Basic Structure, variables Data type, input...Introduction to Java Programming, Basic Structure, variables Data type, input...
Introduction to Java Programming, Basic Structure, variables Data type, input...
Mr. Akaash
 

Similar to Basic of Java (20)

L1 basics
L1 basicsL1 basics
L1 basics
teach4uin
 
Untitled presentation about object oriented.pptx
Untitled presentation about object oriented.pptxUntitled presentation about object oriented.pptx
Untitled presentation about object oriented.pptx
janetvidyaanancys
 
Unit 1- Basic concept of object-oriented-programming.ppt
Unit 1- Basic concept of object-oriented-programming.pptUnit 1- Basic concept of object-oriented-programming.ppt
Unit 1- Basic concept of object-oriented-programming.ppt
hannahroseline2
 
JAVA object oriented programming (oop).ppt
JAVA object oriented programming (oop).pptJAVA object oriented programming (oop).ppt
JAVA object oriented programming (oop).ppt
AliyaJav
 
U1 JAVA.pptx
U1 JAVA.pptxU1 JAVA.pptx
U1 JAVA.pptx
madan r
 
object oriented programming examples
object oriented programming examplesobject oriented programming examples
object oriented programming examples
Abdii Rashid
 
Share Unit 1- Basic concept of object-oriented-programming.ppt
Share Unit 1- Basic concept of object-oriented-programming.pptShare Unit 1- Basic concept of object-oriented-programming.ppt
Share Unit 1- Basic concept of object-oriented-programming.ppt
hannahrroselin95
 
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.pptJava Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
akashsachu221
 
Java Jive 002.pptx
Java Jive 002.pptxJava Jive 002.pptx
Java Jive 002.pptx
AdarshSingh202130
 
Getting Started with JAVA
Getting Started with JAVAGetting Started with JAVA
Getting Started with JAVA
ShivamPathak318367
 
Oop.pptx
Oop.pptxOop.pptx
Oop.pptx
KalGetachew2
 
Elements of Java Language
Elements of Java Language Elements of Java Language
Elements of Java Language
Hitesh-Java
 
Introduction to Java
Introduction to JavaIntroduction to Java
Introduction to Java
Soumya Suman
 
Java ppt-class_Introduction_class_Objects.ppt
Java ppt-class_Introduction_class_Objects.pptJava ppt-class_Introduction_class_Objects.ppt
Java ppt-class_Introduction_class_Objects.ppt
VGaneshKarthikeyan
 
lecture-1111111111111111111111111111.pdf
lecture-1111111111111111111111111111.pdflecture-1111111111111111111111111111.pdf
lecture-1111111111111111111111111111.pdf
harey68956
 
Unit 2.pptx
Unit 2.pptxUnit 2.pptx
Unit 2.pptx
SherinRappai
 
Unit 2.pptx
Unit 2.pptxUnit 2.pptx
Unit 2.pptx
SherinRappai1
 
Features of Object Oriented Programming.pptx
Features of Object Oriented Programming.pptxFeatures of Object Oriented Programming.pptx
Features of Object Oriented Programming.pptx
SwagatoBiswas
 
Session 02 - Elements of Java Language
Session 02 - Elements of Java LanguageSession 02 - Elements of Java Language
Session 02 - Elements of Java Language
PawanMM
 
Java ppt-class_basic data types methods definitions
Java ppt-class_basic data types methods definitionsJava ppt-class_basic data types methods definitions
Java ppt-class_basic data types methods definitions
ganeshkarthy
 
Untitled presentation about object oriented.pptx
Untitled presentation about object oriented.pptxUntitled presentation about object oriented.pptx
Untitled presentation about object oriented.pptx
janetvidyaanancys
 
Unit 1- Basic concept of object-oriented-programming.ppt
Unit 1- Basic concept of object-oriented-programming.pptUnit 1- Basic concept of object-oriented-programming.ppt
Unit 1- Basic concept of object-oriented-programming.ppt
hannahroseline2
 
JAVA object oriented programming (oop).ppt
JAVA object oriented programming (oop).pptJAVA object oriented programming (oop).ppt
JAVA object oriented programming (oop).ppt
AliyaJav
 
U1 JAVA.pptx
U1 JAVA.pptxU1 JAVA.pptx
U1 JAVA.pptx
madan r
 
object oriented programming examples
object oriented programming examplesobject oriented programming examples
object oriented programming examples
Abdii Rashid
 
Share Unit 1- Basic concept of object-oriented-programming.ppt
Share Unit 1- Basic concept of object-oriented-programming.pptShare Unit 1- Basic concept of object-oriented-programming.ppt
Share Unit 1- Basic concept of object-oriented-programming.ppt
hannahrroselin95
 
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.pptJava Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
akashsachu221
 
Elements of Java Language
Elements of Java Language Elements of Java Language
Elements of Java Language
Hitesh-Java
 
Introduction to Java
Introduction to JavaIntroduction to Java
Introduction to Java
Soumya Suman
 
Java ppt-class_Introduction_class_Objects.ppt
Java ppt-class_Introduction_class_Objects.pptJava ppt-class_Introduction_class_Objects.ppt
Java ppt-class_Introduction_class_Objects.ppt
VGaneshKarthikeyan
 
lecture-1111111111111111111111111111.pdf
lecture-1111111111111111111111111111.pdflecture-1111111111111111111111111111.pdf
lecture-1111111111111111111111111111.pdf
harey68956
 
Features of Object Oriented Programming.pptx
Features of Object Oriented Programming.pptxFeatures of Object Oriented Programming.pptx
Features of Object Oriented Programming.pptx
SwagatoBiswas
 
Session 02 - Elements of Java Language
Session 02 - Elements of Java LanguageSession 02 - Elements of Java Language
Session 02 - Elements of Java Language
PawanMM
 
Java ppt-class_basic data types methods definitions
Java ppt-class_basic data types methods definitionsJava ppt-class_basic data types methods definitions
Java ppt-class_basic data types methods definitions
ganeshkarthy
 
Ad

Recently uploaded (20)

CBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - Worksheet
CBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - WorksheetCBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - Worksheet
CBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - Worksheet
Sritoma Majumder
 
How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...
How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...
How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...
Celine George
 
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Celine George
 
Stein, Hunt, Green letter to Congress April 2025
Stein, Hunt, Green letter to Congress April 2025Stein, Hunt, Green letter to Congress April 2025
Stein, Hunt, Green letter to Congress April 2025
Mebane Rash
 
Understanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s GuideUnderstanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s Guide
GS Virdi
 
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...
larencebapu132
 
Presentation on Tourism Product Development By Md Shaifullar Rabbi
Presentation on Tourism Product Development By Md Shaifullar RabbiPresentation on Tourism Product Development By Md Shaifullar Rabbi
Presentation on Tourism Product Development By Md Shaifullar Rabbi
Md Shaifullar Rabbi
 
Introduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe EngineeringIntroduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe Engineering
Damian T. Gordon
 
Anti-Depressants pharmacology 1slide.pptx
Anti-Depressants pharmacology 1slide.pptxAnti-Depressants pharmacology 1slide.pptx
Anti-Depressants pharmacology 1slide.pptx
Mayuri Chavan
 
apa-style-referencing-visual-guide-2025.pdf
apa-style-referencing-visual-guide-2025.pdfapa-style-referencing-visual-guide-2025.pdf
apa-style-referencing-visual-guide-2025.pdf
Ishika Ghosh
 
P-glycoprotein pamphlet: iteration 4 of 4 final
P-glycoprotein pamphlet: iteration 4 of 4 finalP-glycoprotein pamphlet: iteration 4 of 4 final
P-glycoprotein pamphlet: iteration 4 of 4 final
bs22n2s
 
2541William_McCollough_DigitalDetox.docx
2541William_McCollough_DigitalDetox.docx2541William_McCollough_DigitalDetox.docx
2541William_McCollough_DigitalDetox.docx
contactwilliamm2546
 
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Library Association of Ireland
 
Unit 6_Introduction_Phishing_Password Cracking.pdf
Unit 6_Introduction_Phishing_Password Cracking.pdfUnit 6_Introduction_Phishing_Password Cracking.pdf
Unit 6_Introduction_Phishing_Password Cracking.pdf
KanchanPatil34
 
Sinhala_Male_Names.pdf Sinhala_Male_Name
Sinhala_Male_Names.pdf Sinhala_Male_NameSinhala_Male_Names.pdf Sinhala_Male_Name
Sinhala_Male_Names.pdf Sinhala_Male_Name
keshanf79
 
Social Problem-Unemployment .pptx notes for Physiotherapy Students
Social Problem-Unemployment .pptx notes for Physiotherapy StudentsSocial Problem-Unemployment .pptx notes for Physiotherapy Students
Social Problem-Unemployment .pptx notes for Physiotherapy Students
DrNidhiAgarwal
 
YSPH VMOC Special Report - Measles Outbreak Southwest US 5-3-2025.pptx
YSPH VMOC Special Report - Measles Outbreak  Southwest US 5-3-2025.pptxYSPH VMOC Special Report - Measles Outbreak  Southwest US 5-3-2025.pptx
YSPH VMOC Special Report - Measles Outbreak Southwest US 5-3-2025.pptx
Yale School of Public Health - The Virtual Medical Operations Center (VMOC)
 
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulsepulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
sushreesangita003
 
SPRING FESTIVITIES - UK AND USA -
SPRING FESTIVITIES - UK AND USA            -SPRING FESTIVITIES - UK AND USA            -
SPRING FESTIVITIES - UK AND USA -
Colégio Santa Teresinha
 
How to Manage Opening & Closing Controls in Odoo 17 POS
How to Manage Opening & Closing Controls in Odoo 17 POSHow to Manage Opening & Closing Controls in Odoo 17 POS
How to Manage Opening & Closing Controls in Odoo 17 POS
Celine George
 
CBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - Worksheet
CBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - WorksheetCBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - Worksheet
CBSE - Grade 8 - Science - Chemistry - Metals and Non Metals - Worksheet
Sritoma Majumder
 
How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...
How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...
How to track Cost and Revenue using Analytic Accounts in odoo Accounting, App...
Celine George
 
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Celine George
 
Stein, Hunt, Green letter to Congress April 2025
Stein, Hunt, Green letter to Congress April 2025Stein, Hunt, Green letter to Congress April 2025
Stein, Hunt, Green letter to Congress April 2025
Mebane Rash
 
Understanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s GuideUnderstanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s Guide
GS Virdi
 
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...
larencebapu132
 
Presentation on Tourism Product Development By Md Shaifullar Rabbi
Presentation on Tourism Product Development By Md Shaifullar RabbiPresentation on Tourism Product Development By Md Shaifullar Rabbi
Presentation on Tourism Product Development By Md Shaifullar Rabbi
Md Shaifullar Rabbi
 
Introduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe EngineeringIntroduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe Engineering
Damian T. Gordon
 
Anti-Depressants pharmacology 1slide.pptx
Anti-Depressants pharmacology 1slide.pptxAnti-Depressants pharmacology 1slide.pptx
Anti-Depressants pharmacology 1slide.pptx
Mayuri Chavan
 
apa-style-referencing-visual-guide-2025.pdf
apa-style-referencing-visual-guide-2025.pdfapa-style-referencing-visual-guide-2025.pdf
apa-style-referencing-visual-guide-2025.pdf
Ishika Ghosh
 
P-glycoprotein pamphlet: iteration 4 of 4 final
P-glycoprotein pamphlet: iteration 4 of 4 finalP-glycoprotein pamphlet: iteration 4 of 4 final
P-glycoprotein pamphlet: iteration 4 of 4 final
bs22n2s
 
2541William_McCollough_DigitalDetox.docx
2541William_McCollough_DigitalDetox.docx2541William_McCollough_DigitalDetox.docx
2541William_McCollough_DigitalDetox.docx
contactwilliamm2546
 
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Library Association of Ireland
 
Unit 6_Introduction_Phishing_Password Cracking.pdf
Unit 6_Introduction_Phishing_Password Cracking.pdfUnit 6_Introduction_Phishing_Password Cracking.pdf
Unit 6_Introduction_Phishing_Password Cracking.pdf
KanchanPatil34
 
Sinhala_Male_Names.pdf Sinhala_Male_Name
Sinhala_Male_Names.pdf Sinhala_Male_NameSinhala_Male_Names.pdf Sinhala_Male_Name
Sinhala_Male_Names.pdf Sinhala_Male_Name
keshanf79
 
Social Problem-Unemployment .pptx notes for Physiotherapy Students
Social Problem-Unemployment .pptx notes for Physiotherapy StudentsSocial Problem-Unemployment .pptx notes for Physiotherapy Students
Social Problem-Unemployment .pptx notes for Physiotherapy Students
DrNidhiAgarwal
 
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulsepulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
sushreesangita003
 
How to Manage Opening & Closing Controls in Odoo 17 POS
How to Manage Opening & Closing Controls in Odoo 17 POSHow to Manage Opening & Closing Controls in Odoo 17 POS
How to Manage Opening & Closing Controls in Odoo 17 POS
Celine George
 
Ad

Basic of Java

  • 1. Presentation By:- Ajeet Kumar Verma B.C.A 3rd yr
  • 2. PROGRAMMING IN JAVA Introduction to JAVA Topic:-Genesis and overview of Java
  • 3. Contents • What is JAVA? ● • What is OOPs? ● • Why Java? ● Characteristics of JAVA ● Overview of Java. ● The difference between Java and C++? ● A Simple JAVA Program
  • 4. What is JAVA? ● Developed by Sun Microsystems (James Gosling) ● A general-purpose Object-Oriented language ● Based on C/C++ ● Designed for easy Web/Internet applications ● Widespread acceptance
  • 5. What is Object Oriented Programming? ● Object-oriented programming is a method of implementation in which programs are organized as cooperative collections of objects, each of which represents an instance of some class, and whose classes are all members of one or more hierarchy of classes united via inheritance relationships.
  • 6. Principles of OOP ● All object-oriented programming languages provide mechanisms that help you implement the objectoriented model. • They are:-- ● Encapsulation ● Inheritance ● Polymorphism
  • 7. Data Encapsulation ● Encapsulation is the mechanism that binds together code and the data it manipulates, and keeps both safe from outside interference and misuse. ● Example:- class Account { int x=10; float withdraw(); void deposit(float amount); float balance; }
  • 8. Advantages of Encapsulation ● Protection ● Consistency ● Allows change
  • 9. Inheritance ● Inheritance is the process by which one object acquires the properties of another object. ● A class that is derived from another class is called a subclass (also a derived class, extended class, or child class). ● The class from which the subclass is derived is called a super class (also a base class or a parent class). ● A class which is a subtype of a more general class is said to be inherited from it.
  • 10. Inheritance cont’d ● The sub-class inherits the base class’ data members and member functions. ● A sub-class has all data members of its base-class plus its own. ● A sub-class has all member functions of its base class (with changes) plus its own.
  • 11. Polymorphism ● Polymorphism refers to a programming language's ability to process objects differently depending on their data type or class. ● Generally, the ability to appear in many forms. ● More specifically, it is the ability to redefine methods for derived classes. ● For example, given a base class shape, polymorphism enables the programmer to define different area methods for any number of derived classes, such as circles, rectangles and triangles. No matter what shape an object is, applying the area method to it will return the correct results.
  • 12. Why Java? ● Java is the Internet programming language. ● Java enables users to develop and deploy applications on the Internet for servers, desktop computers, and small hand-held devices.
  • 13. Characteristics of Java ● Java Is Simple ● Java Is Object-Oriented ● Java Is Distributed ● Java Is Interpreted ● Java Is Robust ● Java Is Secure ● Java Is Architecture-Neutral ● Java Is Portable ● Java's Performance ● Java Is Multithreaded ● Java Is Dynamic
  • 14. JDK Versions ● JDK 1.02 (1995) … 250 classes ● JDK 1.1 (1996) … 500 classes ● JDK 1.2 (1998) … 2300 classes ● JDK 1.3 (2000) … 2300 classes ● JDK 1.4 (2002) … 2300 classes ● JDK 1.5 (2004) … 3500 classes ● JDK 1.6 (2006) … 3500 classes ● JDK 1.7 (2011) … 3500 classes
  • 15. A Simple Java Program ● //This program prints Welcome to Java! public class Welcome { public static void main(String[] args) { System.out.println("Welcome to Java!"); { {