Created
December 13, 2015 17:34
-
-
Save Yur-ok/6347031f4c3034f0e752 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package Lesson2.KeyPoint4; | |
/** | |
* Created by Юрий on 14.12.2015. | |
*/ | |
public class PrintNumbers { | |
public static void main(String[] args) { | |
printNumbers(5,7); | |
printNumbers(-2,4); | |
} | |
static void printNumbers(int i, int n) { | |
while (i < n) { | |
n++; | |
System.out.println(n); | |
return; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
По заданию нужно было не выход из метода, а изменить данные в условии цикла