Here you can find the source of size(Object[] list)
public static int size(Object[] list)
//package com.java2s; //License from project: Apache License import java.util.List; public class Main { public static int size(Object[] list) { if (list == null) { return 0; } else {/*from w ww .jav a 2s .c om*/ return list.length; } } public static int size(List<?> list) { if (list == null) { return 0; } else { return list.size(); } } }