Skip to content

Commit a44f2c8

Browse files
Merge pull request #6 from MPMyburgh/patch-1
Change peek() to poll() to clarify functionality
2 parents c96230b + 3421bad commit a44f2c8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: collections-questions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1553,7 +1553,7 @@ Hbase
15531553
```
15541554
**The poll() method**
15551555

1556-
The peek() method of the Queue interface returns the object at the top of the current queue and removes it. If the queue is empty this method returns null.
1556+
The poll() method of the Queue interface returns the object at the top of the current queue and removes it. If the queue is empty this method returns null.
15571557

15581558
```java
15591559
import java.util.Iterator;

0 commit comments

Comments
 (0)