我来自.net背景。但是,java / c#基本相同。如果您实例化非基本类型(在您的情况下为数组),则该类型不会为null。例如,int[] numbers = new int[3];在这种情况下,将分配空间且每个元素的默认值为0。这将是null,当你做不new起来。例如int[] numbers = null; // changed as per @Joachim's suggestion.if (numbers == null){ System.out.println("yes, it is null. Please new it up");}