change newline to null then newline
This commit is contained in:
parent
f4b576029a
commit
10a3a6fb3a
Binary file not shown.
|
@ -12,7 +12,7 @@ public class Replace {
|
|||
|
||||
public static void printArray(int[] a) {
|
||||
if(a==null) {
|
||||
System.out.println(); //Create a newline to make the format looks uniform
|
||||
System.out.println("null"); //Print the string null
|
||||
return; //If a is a null pointer, return immediately to prevent a NullPointerException
|
||||
}
|
||||
//NOTE: return; (a return statement without a return value) in a method with no return type will break out of the method.
|
||||
|
|
Loading…
Reference in New Issue