Domanda di colloquio di Volante Technologies

3. Sort elements using String ArrayList Example Sort the array elements order by A-Z Input: Array={“Arun”,”sector”,”checking”,”merge”,”define”,”generate”} 4.Take a string and use “ Collection” concept and print the results Example Given input some word? EX: Input: TESTINGFILE Print the output collection? EX: Output: FIGTTSEEINI

Risposta di colloquio

Anonimo

18 ago 2017

class Demo{ public static void main(String args[]){ String Array[]={"Arun","sector","checking","merge","define","generate"}; List al=new ArrayList(Arrays.asList(Array)); Collections.sort(al); System.out.println(al);} }