0% found this document useful (0 votes)
3 views27 pages

Java Complete Notes

The document provides an overview of Java programming concepts including data types, operators, control structures, exceptions, and object-oriented principles. It discusses the Java Development Kit (JDK), Java Runtime Environment (JRE), and Java Virtual Machine (JVM), along with examples of variable declarations and method definitions. Additionally, it touches on error handling, collections, and the use of System class methods.
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)
3 views27 pages

Java Complete Notes

The document provides an overview of Java programming concepts including data types, operators, control structures, exceptions, and object-oriented principles. It discusses the Java Development Kit (JDK), Java Runtime Environment (JRE), and Java Virtual Machine (JVM), along with examples of variable declarations and method definitions. Additionally, it touches on error handling, collections, and the use of System class methods.
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

int

javac

javac
.class

.class

.class
javac
javadoc jdb jar

JDK ⊃ JRE ⊃ JVM

byte

short

int

long L

float f F

double

char

boolean

char

3.14 double float f float f


= 3.14f;
100000000000 L long l = 100000000000L;
byte b = 130; byte b = (byte)130;

null

+ - * / %

+ - ++ -- !

== != > < >= <=

condition ? expr1 : expr2

% 5.5 % 2 = 1.5
&& || & |

>> >>>

++i i++

i = i++ + ++i;
if if

else if

break
switch byte, short, char, int enum String
long float double boolean

val val

ConcurrentModificationException

break
continue
[Link]()
[Link] [Link]()

Object[] objArr = new String[3];


objArr[0] = 10; ArrayStoreException
.equals()
== [Link]()
+

java Demo Hello World 123 args = {"Hello", "World", "123"}

[Link](args[2])

main public static void main(String[] args)


static
String[] Args static NoSuchMethodError: main

int→Integer, char→Character,
boolean→Boolean, byte→Byte, short→Short, long→Long, float→Float, double→Double

ArrayList HashMap

[Link] Integer.MAX_VALUE

Integer IntegerCache
.equals() ==

null NullPointerException
Student s2 = s1; s2 s1
s2 s1

void
new
int add(int,int)
double add(int,int)

foo(5) foo(long) foo(Integer)


foo(long)
StackOverflowError

new
new

this

this(...)
this(...) super(...)

static

static
this super
main

main()

finalize()

try-with-resources Cleaner AutoCloseable


finalize()
private

protected

public

static final abstract synchronized transient


volatile native

public
private protected public .java
[Link] Inner()
new Shape()
super()

abstract
abstract
class C extends A, B

super(args)
super(args)
super()

public protected
static final private

@Override

static
super

final

final
final

public static final

public abstract
default static private
public abstract
implement

instanceof

instanceof
ClassCastException
Animal

Object

[Link]
equals() hashCode()
equal()
hashCode() HashMap HashSet
abstract class interface

default static private

public static final

extends implements

private protected public


public private

Comparable Runnable

[Link]()

System [Link]
[Link]() [Link]() [Link]()
final
out System PrintStream

println() PrintStream
print()

[Link](...) out
System println

[Link]
[Link](PrintStream)

== .equals()
==
new String()

equals() hashCode()
ArrayStoreException
finalize()
null
break

final

You might also like