java Argv. for JAVA on Eclipse 很多時候程式的設計都是利用執行時的參數傳遞當做input,不只在c/c++有這樣的作法,JAVA也不例外。 public static void main(String[] args){ 作法如下: 進入Run configuration中,設定Variable。 <img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAycAAAB4CAIAAABn+xpBAAAXTmlDQ1BJQ0MgUHJvZmlsZQAAeAHVWWdYFM2y7plNwLKkJeccRXKWnCRIDoJIWtKScw5KUoIgiICAoIAIIoIYCAIiYAJEgoARCaIgqGACBOEO6vd95z7nnH/3z+3n2Z53q6qra6d6uqfeBYBt2S042B+mAyAgMDzUylCH96CDIy/uBYAABSAAPkDvRgoL1rawMAX/tX2fQKyRNia56+u/mv1nBb2HZxgJAMgCUbt7hJECEHwdAFiHFBwaDgBqHZEPR4UHIxj9AMGMoUiACH65i71/45Vd7P4LY9C/bGysdAHAsAJAQe3mFuoNAEEQkfNGkrwRPwQ9ALAMgR7kQACIBxGsQfJx8wCArRix2RMQELSL+xAs6v4vfrz/Bbu5uf/t083N+2/8+7cgI5GJ9chhwf5uMb++/F92Af4RyP361RiQnjrQ32w3N8zIZ8HDTc8EuXIin+1g/185Q2wgds9AW2tEtov3BLqbmf/BGl6hBlYIRsZCFsHhOrsYuWeQV3C4hc0feWKsj64ZgqkReYFnmP5ffs75uhnv5owGkTeHRljZIlgQwd1hkdb6CEZWFPQm1sfG/