Hi all,
import java.io.*;
import java.util.*;
class MapDemo{
public static void main(String args[]){
Map<Integer, Object[]> tMap = new TreeMap<Integer, Object[]>();
Object[] values = new String[] {"Tree", "Map"};
tMap.put(1, values);
System.out.println("Keys of tree map: " + tMap.keySet());
System.out.println("Values of tree map: " + Arrays.deepToString(tMap.values().toArray()));
}
}
The above code works good to print the array of String values. But, the issue is, I need to read the keys and values from a .CSV file by just giving the name of the file.
Any ideas??