Here you can find the source of reverse(final List
public static <T> List<T> reverse(final List<T> list)
//package com.java2s; //License from project: Apache License import java.util.*; public class Main { public static <T> List<T> reverse(final List<T> list) { final ArrayList<T> result = new ArrayList<>(list); Collections.reverse(result); return result; }/*w w w .j a v a 2 s . co m*/ }