You are on page 1of 4

DAY 1 LEARNIGS

Jeera Techno
07:23

JAVA NOTATIONS(CODING STANDARD) --------------------------------


1.Pascal
2.Camel

Pascal -------- Starts with capital letter


ex: Test, Sample, Afroz, Java
-->Project, Class, Interface

Camel ----- starts with small letter


ex: empId, empName, cmpName, cmpAddress, empMobile
-->Package, methods, variables

How to create project

File-->New-->Project/JavaProject-->(Name in Pacal format)

How to crate package

Right click on src-->new-->package-->(Camel format)

How to create class

Rightclick on package-->new-->Class-->(Name in pascal)


DAY 3 LEARNIGS

Inheritance ----------- We can use one class properites(Methods) into another class by using 'extends'
keywords.
The main reason we are going for inheritance is to avoid multiple object creation. i.e. Memory wasteage will be
low and Code Reusability will increase.

Types of inheritance ------------------


1.Single Inheritance
= one parent class and one child class
2.Multiple Inheritance
= wont support in java...priorty problem... deadly diamond
problem
3.Multi-level Inheritance
=Level by level scenario it will follow
4.Hybrid Inheritance
= Combination of any two inheritances
5.Hierarchical Inheritance.
= ONe parent class can accessable to multiple child
classes
DAY 4 LEARNIGS

Data Type

We can store our desired values with the help of types.

DataTypes available in java

byte
short
int
long
float
double
char
boolean
String

syntax

DataType variable = value;


Data Default Default
Type Value size

boolean false 1 bit


char '\u0000’ 2 byte
byte 0 1 byte
short 0 2 byte
int 0 4 byte
long 0L 8 byte
float 0.0f 4 byte
double 0.0d 8 byte

Datatype Size Description


byte 1 byte Stores whole numbers from -128 to 127
short 2 bytes Stores whole numbers from -32,768 to 32,767
int 4 bytes Stores whole numbers from -2,147,483,648 to 2,147,483,647
long 8 bytes Stores whole numbers from -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807
float 4 bytes Stores fractional numbers. Sufficient for storing 6 to 7 decimal digits
double 8 bytes Stores fractional numbers. Sufficient for storing 15 decimal digits
boolean 1 bit Stores true or false values
char 2 bytes Stores a single character/letter or ASCII values

ASCII - American Standard Code Information interchange

You might also like