how to make a pre set list java

Java
        List<String> aList = Arrays.asList("Geeks", "for", 
                     "GeeksQuiz", "GeeksforGeeks", "GFG"); 
Source

Also in Java: