D
Daniel Giaimo
I ran into an interesting piece of code today which I had a fairly strong
reaction to, and I was wondering if it was just me, or whether other
people feel the same way about it. I don't really want to bias the
sample by saying whether I liked the code or not, so I'll just ask, how
do you feel about the following code for iterating over an array?
int[] arr = {1, 2, 3, 4}
for(int i=arr.length; i-->0
{
System.out.println(arr);
}
--
Dan Giaimo
reaction to, and I was wondering if it was just me, or whether other
people feel the same way about it. I don't really want to bias the
sample by saying whether I liked the code or not, so I'll just ask, how
do you feel about the following code for iterating over an array?
int[] arr = {1, 2, 3, 4}
for(int i=arr.length; i-->0
{
System.out.println(arr);
}
--
Dan Giaimo