O'Reilly logo
  • Michael ss thinks this is interesting:

Looping Using the for-each Construct

You can easily use the for-each construct, discussed earlier, to loop through all the elements of a two-dimensional array. For example, to loop through the elements of the marks array declared in the previous example, use the following block of code:


Cover of Java Programming