Excessive comment, whops
This commit is contained in:
parent
10a3a6fb3a
commit
a638a4a409
|
@ -16,7 +16,7 @@ public class Replace {
|
|||
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.
|
||||
for(int i = 0;i<a.length;i++)System.out.format("%d%s",a[i],i==a.length-1?"\n":","); //Loop from i to a.length use a ternary operator to determine if value printed is the last one, if it is, create a new line , if not, insert a comma (')for(int i = 0;i<a.length;i++)System.out.format("%d%s",a[i],i==a.length-1?"\n":","); //Loop from i to a.length use a ternary operator to determine if value printed is the last one, if it is, create a new line , if not, insert a comma (')
|
||||
for(int i = 0;i<a.length;i++)System.out.format("%d%s",a[i],i==a.length-1?"\n":","); //Loop from i to a.length use a ternary operator to determine if value printed is the last one, if it is, create a new line , if not, insert a comma (')
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
|
|
Loading…
Reference in New Issue