Skip to content

Prority Queue (or) Min Heap(Small To BiG) default implementation - Numbers sorting #83

@SharedMocha

Description

@SharedMocha

import java.util.*;
public class HelloWorld{

 public static void main(String []args){
    System.out.println("Hello World");
    PriorityQueue<Integer> temp = new PriorityQueue<Integer>();
    temp.add(10);
    temp.add(1);
    temp.add(64);
    temp.add(3);
    
    while(!temp.isEmpty()){
        System.out.println(temp.poll());
    }
    
    
 }

}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions