new semester, new repo structure
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
|
||||
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
|
||||
*/
|
||||
package practiceexam2;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author caleb
|
||||
*/
|
||||
public class TransformToDOWhileLoops {
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
int i = 1;
|
||||
do {
|
||||
int j = 1;
|
||||
|
||||
do {
|
||||
|
||||
j += 2;
|
||||
if (i % 2 == 0) {
|
||||
continue;
|
||||
}
|
||||
System.out.print(j + " ");
|
||||
} while (j <= i + 1);
|
||||
System.out.println();
|
||||
++i;
|
||||
} while (i <= 9);
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user