This commit is contained in:
ScorpioMiku
2019-09-11 18:42:43 +08:00
parent 8a3d565c88
commit f6485e3e4d
20 changed files with 573 additions and 159 deletions

View File

@@ -94,4 +94,7 @@ public class Main {
return jsonObject;
}
}

View File

@@ -0,0 +1,23 @@
import java.util.ArrayList;
import java.util.List;
public class test {
public static void main(String[] args) {
int size = 6;
int i = 0, step = 0;
List<Integer> list = new ArrayList<>();
for (int j = 0; j < size; j++) {
list.add(j);
}
while (step < size / 2) {
System.out.println(list.get(i));
System.out.println(list.get(i + 1));
i += 2;
System.out.println("------------");
step += 1;
}
if (step * 2 < size) {
System.out.println(list.get(i));
}
}
}