public boolean remove(PageId pageNo) {
      
    // Instantiate current and previous entries
    BufHTEntry cur, prev = null;
      
    // Removes INVALID_PAGE
    if (pageNo.pid == INVALID_PAGE)
      return true;
    
    // Determine the pageNo's bucket using the hash function  
    int index = hash(pageNo);
    
    // Iterate through the Page Table linked list until the pageNo is found
    // or the end of the linked list is found
    for (cur = ht[index]; cur != null; cur = cur.next) {
      if (cur.pageNo.pid == pageNo.pid)
        break;
      prev = cur;
    }
    
    // If the current entry is not null, remove the current entry
    if (cur != null) {
      // If the there is more than one entry in this bucket
      if (prev != null)
        prev.next = cur.next;
      // There is only one entry in this bucket 
      else
        ht[index] = cur.next;
    // The current entry is null meaning the pageNo is not in the Page Table
    } else {
      System.out.println ("ERROR: Page " + pageNo.pid + " was not found in hashtable.");
      // The pageNo was not removed from the Page Table
      return false;
    }
    
    // The pageNo was removed from the Page Table
    return true;
    
  } //end remove()