- Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathElement.java
More file actions
Latest commit
23 lines (21 loc) · 459 Bytes
/
Copy pathElement.java
File metadata and controls
23 lines (21 loc) · 459 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
packagecom.codinginterview.dsa.stack;
publicclassElement<T> {
privateTdata;
privateElementnext;
publicTgetData(){
returndata;
}
publicvoidsetData(Tdata){
this.data = data;
}
publicElementgetNext(){
returnnext;
}
publicvoidsetNext(Elementnext){
this.next = next;
}
publicElement(Tdata, Elementnext){
this.data = data;
this.next = next;
}
}