语言、程序、软件、软件系统 口源代码的“编译 ■编译器能够一次性将程序中的所有语句转换生成机器语言代码,又 称目标代码,之后目标代码又被处理器处理。 public class convert 0lll001010 fint fahrenheit=0 int Celsius=0; 编译器 fahrenheit= system in reado system. out print& 011001001010 源代码 目标代码处理器
源代码的“编译” ◼ 编译器能够一次性将程序中的所有语句转换生成机器语言代码,又 称目标代码,之后目标代码又被处理器处理。 11 一、语言、程序、软件、软件系统 public class convert { go {int fahrenheit=0; int Celsius=0; fahrenheit= system.in.read(); system.out.print{} 011111001010 101011100011 011001001010 100111001010 111111001011 011001001010 源代码 编译器 目标代码 处理器
12 语言、程序、软件、软件系统 口源代码的“解释 ■解释器在程序运行时,一次只能转换并执行条语句。在一条语句 被执行后,解释器会转换并执行下一条语句,并会一直执行这种操 作,直到程序运行结束 public class convert fint fahrenheit=0 int celsius=o int Celsius=0. 解释器 fahrenheit= system In reado system. out. print 源代码 目标代码 处理器
源代码的“解释” ◼ 解释器在程序运行时,一次只能转换并执行一条语句。在一条语句 被执行后,解释器会转换并执行下一条语句,并会一直执行这种操 作,直到程序运行结束 12 一、语言、程序、软件、软件系统 public class convert { go {int fahrenheit=0; int Celsius=0; fahrenheit= system.in.read(); system.out.print{} 011111001010 源代码 解释器 目标代码 处理器 int Celsius=0
语言、程序、软件、软件系统 if(op1=op2 DV eax, op1 X=1 p eax, op2 Y=2: L1 VⅩ,1 1010 Y,2; 0011 L1: 1010 1101 share
13 一、语言、程序、软件、软件系统 011111001010 101011100011 011001001010 01010101101 mov eax, op1 cmp eax,op2 ; jne L1 ; mov X, 1 ; mov Y, 2; L1: if( op1 = op2 ) { X = 1; Y = 2; }
High Level Language Easy for Programmers 00 and Visual Language to understand Con lains Engilish words FORTRAN C Pascal High-Level Language Assembly Language Low Level Langugae The computers own Machine Language Language Binary numbers, in I's and O's Hardware justcode me
语言、程序、软件、软件系统 谈谈程序 ■使用计算机语言,编写岀的规范代码,用以实现特定任务。 ■语法 if( op1=op2) ■算法 排序/查询 X=1: 算法 语法 Cloud share
一、语言、程序、软件、软件系统 谈谈程序 ◼ 使用计算机语言,编写出的规范代码,用以实现特定任务。 ◼ 语法 ◼ 算法 if( op1 = op2 ) { X = 1; Y = 2; } 排序 / 查询 语法 算法