評分:1, 年:1, 月:1, 週:1, 日:1, [+1 / -1] 最後更新:2022-03-01 09:14:35
白天都不想畫畫...寫了一個練習課題產生器
不過也不會照著練...= =
[aa]
import java.util.Scanner;
public class PaintingPractice {
public static Scanner scanner = new Scanner(System.in);
public static void main(String[] args) {
String[] type = {"武器","上色","植物","分鏡","下半身","肌肉","服裝","背部","背景","五官","姿勢","構圖","綜合練習","頭髮"};
int count = 14;
System.out.println("今天要做幾項練習? (MAX:5)");
char n;
do{
n = scanner.next().charAt(0);
if(n < 49 || n > 53)
System.out.print("輸入錯誤");
}while(n < 49 || n > 53);
System.out.println("本日練習:");
for(int i = 0;i < (n - 48);i++){
int random = (int)(Math.random() * count);
System.out.println((i + 1) + "." + type[random]);
count--;
for(int j = random;j < count;j++)
type[j] = type[j + 1];
}
}
}
[/aa]