Skip to content

Commit 39d4ae3

Browse files
committed
more programs in OOps added
1 parent 5572a7c commit 39d4ae3

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

OOPs/Employee.java

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
public class Employee {
2+
// properties
3+
int salary;
4+
String name;
5+
// methods
6+
int getSalary(){
7+
return this.salary;
8+
}
9+
String getName(){
10+
return this.name;
11+
}
12+
void setName(String n){
13+
this.name = n;
14+
}
15+
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy