Android examples for java.lang:array
count Null in an array
//package com.book2s; public class Main { public static <T> int countNull(T[] src) { int ret = 0; int srclen = src.length; for (int i = 0; i < srclen; ++i) { if (src[i] == null) { ++ret;/*from www . j av a 2 s. c o m*/ } } return ret; } }