MCPcopy Create free account
hub / github.com/apna-college/Alpha / peek

Method peek

13_Stacks/StackLL.java:39–45  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

37 }
38
39 public static int peek() {
40 if(isEmpty()) {
41 return -1;
42 }
43 Node top = head;
44 return top.data;
45 }
46 }
47
48 public static void main(String args[]) {

Callers 8

mainMethod · 0.95
stockSpanMethod · 0.95
mainMethod · 0.95
isValidMethod · 0.95
mainMethod · 0.95
isValidMethod · 0.95
maxAreaMethod · 0.95
maxAreaMethod · 0.95

Calls 1

isEmptyMethod · 0.95

Tested by

no test coverage detected