標籤:漢語 計算 obj imp 應用 來源程式 nbsp target 編寫
進階電腦語言 便於人編寫,閱讀交流,維護。 機器語言是電腦能直接解讀、啟動並執行。
編譯器將彙編或進階電腦語言來源程式 (Source program)作為輸入,翻譯成目標語言(Target language)機器代碼的等價程式。
原始碼一般為進階語言 (High-level language),
如Pascal、C 、C++、Java、漢語編程等或組合語言 ,而目標則是機器語言的目標代碼(Object code),有時也稱作機器代碼(Machine code)。
1 package Com.Table; 2 import java.util.Scanner; 3 public class FourTable { 4 //輸入語句的應用 5 public static void main(String [] args) 6 { 7 System.out.println("學號:"); 8 Scanner scanner = new Scanner(System.in); 9 int Student = scanner.nextInt();10 int StudentYear = Student / 10000;11 int StudentTime = (Student / 100) % StudentYear;12 int StudentId = Student % (Student / 100);13 System.out.println("學生學號:" + Student);14 System.out.println("學生入學年份:" + StudentYear + "年");15 System.out.println("學生期數:" + StudentTime + "期");16 System.out.println("學生序號:" + StudentId + "號");17 }18 }
編譯器將彙編或進階電腦語言來源程式作為輸入