Menu
Question Index
...

What will be the output of the following program?

import java.util.*;
public class Players {
    public static void main(String args[]) {
        NavigableMap plr = new TreeMap();
        plr.put("100", "Sachin");
        plr.put("90", "Dravid");
        plr.put("91", "Yuvraj");
        String it = (String) plr.floorKey("89");
        System.out.print(it);
    }
}


90
100
91
null
Compilation Error or Runtime Error

Doubts

Problems

Topic: TreeMap In Java - java.util.TreeMap

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App