mirror of
https://github.com/Dichgrem/Java.git
synced 2025-12-16 20:42:00 -05:00
start:java8
This commit is contained in:
16
com/study/demo/test1_2.java
Normal file
16
com/study/demo/test1_2.java
Normal file
@@ -0,0 +1,16 @@
|
||||
package com.study.demo;
|
||||
|
||||
public class test2_for {
|
||||
public static void main(String[] args) {
|
||||
int[] numbers = new int[5];
|
||||
for (int i = 0; i < numbers.length; i++) {
|
||||
numbers[i] = i * 10;
|
||||
}
|
||||
|
||||
System.out.print("数组内容: ");
|
||||
for (int i = 0; i < numbers.length; i++) {
|
||||
System.out.print(numbers[i] + " ");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user