---
# System prepended metadata

title: '006public class For結構式 {'

---

# 006public class For結構式 {
for (初值設定 ; 條件判斷 ; 計次) {敘述}
99乘法表
```
```

	public static void main(String[] args) {
		for (int k=0; k<=1; k++){
			for (int j=1; j<=9; j++){
				// 2 x 1 = 2 3 x 1 = 3 ...... 5 x 1 = 5
				for (int i=2; i<=5; i++){
					int newi = i + k*4;
					int result = newi * j;
					System.out.print(newi + " x " + j + " = " + result + "\t");
				}
				System.out.println();
			}
			System.out.println("-----------------------------------------------");
		}
	}

}
```
```
