code: public static <E> edu.stanford.nlp.util.PriorityQueue<E> toPriorityQueue(Counter<E> c) {
      edu.stanford.nlp.util.PriorityQueue<E> queue = new BinaryHeapPriorityQueue<E>();
      for (E key : c.keySet()) {
        double count = c.getCount(key);
        queue.add(key, count);
      }
      return queue;
    }
docs: TODO: rewrite to use entrySet()