Skip to content

Commit 7737df9

Browse files
committed
update the return statement inside the body of the isEmpty() method
1 parent 79d7f6e commit 7737df9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: src/stack/usingLinkedList/implementation/LinkedListStack.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,6 @@ public E pop() {
116116
*/
117117
@Override
118118
public boolean isEmpty() {
119-
return false;
119+
return topOfStackRef == null;
120120
}
121121
}

0 commit comments

Comments
 (0)