You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Driver.java 432B

123456789101112131415161718
  1. public class Driver {
  2. public static void main(String[] args) { test(); }
  3. public static void test() {
  4. // local variable declaration in the init part of a for
  5. for (int i = 0, j = 0; j < 10 ; i++, j++) {
  6. j++;
  7. }
  8. int m, n, j = 0;
  9. // init part without local var declaration
  10. for (m = 0, n = 0; j < 10 ; m++, n++) {
  11. j++;
  12. m++;
  13. }
  14. }
  15. }