public static void main(String[] args) {
        List<String> abc = new ArrayList();
        abc.add("one");
        abc.add("two");
        abc.add("three");

        Object[] a1 = abc.toArray();
        System.out.println(Arrays.asList(a1));

        String[] a2 = new String[2];
        abc.toArray(a2);
        System.out.println(Arrays.asList(a2));

        String[] a3 = new String[3];
        abc.toArray(a3);
        System.out.println(Arrays.asList(a3));
    }

猜猜输出结果?

11-09 19:15