Search:

Type: Posts; User: Scotty33

Search: Search took 0.19 seconds.

  1. Replies
    9
    Views
    1,951

    Re: generate priority queue from hashmap help

    I guess I don't use the node class currently and what im thinking is wrong now is that i should be creating nodes with the char and frequency then put the nodes into the priority queue.

    Does that...
  2. Replies
    9
    Views
    1,951

    Re: generate priority queue from hashmap help

    The node class is used to generate a priority queue of nodes (if my understanding of nodes is correct), each node is suppose to contain the character and its frequency. The node is then added to the...
  3. Replies
    9
    Views
    1,951

    Re: generate priority queue from hashmap help

    I didn't my friend just pointed that out...
    So I changed where I created my PQ to...


    PriorityQueue<Node> pq= new PriorityQueue<Node>();

    Also he suggested I change my compareTo class to

    ...
  4. Replies
    9
    Views
    1,951

    Re: generate priority queue from hashmap help

    Well I need to see the priority queue print out in the correct order... If my understanding of PQ's is correct then it should either print out smallest to largest or largest to smallest but mine does...
  5. Replies
    9
    Views
    1,951

    generate priority queue from hashmap help

    Hey guys I'm new here and was came here hoping to find an answer to my problem. I've never used priority queues before so I'm not sure I'm doing it right but here it goes...

    I'm trying to create a...
Results 1 to 5 of 5