MCPcopy Create free account
hub / github.com/StudyRust/leetcode_rust / peek

Method peek

232-implement-queue-using-stacks.rs:23–25  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

21 }
22
23 fn peek(&self) -> i32 {
24 self.v[0]
25 }
26
27 fn empty(&self) -> bool {
28 self.v.len() == 0

Callers 1

mainFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected