Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import java.util.List;
import java.util.PriorityQueue;

public class Main {
    public static PriorityQueue<Integer> fill(PriorityQueue<Integer> pq, int size) {
        for (int i = 0; i < size; i++) {
            pq.add(0);
        }
        return pq;
    }

    public static List<Integer> fill(List<Integer> list, Integer size) {
        for (int i = 0; i < size; i++) {
            list.add(0);
        }
        return list;
    }
}