-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathintroduction_Oops.txt
More file actions
28 lines (21 loc) · 911 Bytes
/
introduction_Oops.txt
File metadata and controls
28 lines (21 loc) · 911 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
Java is Object oriented programming language
if i am using pen that is an object everything around us is object.
every object has two things -> does somethings -> and knows somethings
and when i am saying that has something -> that are properties,
and what does it do -> e.g. with pen write something...
whatever project you are making you will be having something
you have to treat everything as object.
for example add two numbers
looks at this example
public class Demo{
public static void main(String a[]){
}
}
in order to create an object in java we need to create a class first
// object -> class
// who creates objects in real life
company-> makes pen ->
company->has prototype (or a design or blueprint) -> to make a pen-> that is class in real life
here we create a class and give it to jvm and we get object
lets move to code now
this was introduction.