Skip to content

Commit

Permalink
Fix some typo
Browse files Browse the repository at this point in the history
  • Loading branch information
BigEgg committed Nov 9, 2014
1 parent 72b971f commit adc6474
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
8 changes: 4 additions & 4 deletions java/Algorithms/src/Collections/MaxPriorityQueue.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,19 +55,19 @@ public MaxPriorityQueue(Key[] keys) {
}

/**
* Returns a largest key on the priority queue.
* Returns the largest key on the priority queue.
*
* @return a largest key on the priority queue
* @return the largest key on the priority queue
* @throws java.util.NoSuchElementException if the priority queue is empty
*/
public Key max() {
return first();
}

/**
* Removes and returns a largest key on the priority queue.
* Removes and returns the largest key on the priority queue.
*
* @return a largest key on the priority queue
* @return the largest key on the priority queue
* @throws java.util.NoSuchElementException if priority queue is empty.
*/
public Key delMax() {
Expand Down
8 changes: 4 additions & 4 deletions java/Algorithms/src/Collections/MinPriorityQueue.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,19 +56,19 @@ public MinPriorityQueue(Key[] keys) {


/**
* Returns a smallest key on the priority queue.
* Returns the smallest key on the priority queue.
*
* @return a smallest key on the priority queue
* @return the smallest key on the priority queue
* @throws java.util.NoSuchElementException if priority queue is empty
*/
public Key min() {
return first();
}

/**
* Removes and returns a smallest key on the priority queue.
* Removes and returns the smallest key on the priority queue.
*
* @return a smallest key on the priority queue
* @return the smallest key on the priority queue
* @throws java.util.NoSuchElementException if the priority queue is empty
*/
public Key delMin() {
Expand Down
4 changes: 2 additions & 2 deletions java/Algorithms/test/Collections/PriorityQueueTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public void testInsert() throws Exception {
}

@Test(expected = NoSuchElementException.class)
public void testFirst_NullItem() throws Exception {
public void testFirst_Empty() throws Exception {
MockPriorityQueue pq = new MockPriorityQueue();
pq.first();
}
Expand All @@ -60,7 +60,7 @@ public void testFirst() throws Exception {
}

@Test(expected = NoSuchElementException.class)
public void testDelete_NullItem() throws Exception {
public void testDelete_Empty() throws Exception {
MockPriorityQueue pq = new MockPriorityQueue();
pq.delete();
}
Expand Down

0 comments on commit adc6474

Please sign in to comment.