Computer English
Chapter 7 Programming
Languages
Chapter 7 Programming Languages
计算机专业英语 7-2
Key points:
useful terms and definitions of
programming languages
Difficult points:
describing the differences
between compilers and interpreters
Chapter 7 Programming Languages
计算机专业英语 7-3
Requirements:
1,The origins of the programming languages
2,The concepts of computer compilers
3,Main properties of object-orientation
4,了解 UML,掌握复杂定语从句的翻译技巧
Chapter 7 Programming Languages
计算机专业英语 7-4
New Words & Expressions:
evolution n.发展, 演变 primitive 原始的,
appropriating 适当的 interpreter 解释程序
compiler 编译器 intermediary中间的
invoke 调用 premium 额外费用, 奖金
cryptic 秘密 (含义模糊 )的 esoteric 深奥的
prompt n.提示符
7.1 Computer Languages
Abbreviations:
Chapter 7 Programming Languages
计算机专业英语 7-5
Computer languages have undergone dramatic evolution since
the first electronic computers were built to assist in telemetry
calculations during World War Ⅱ, Early on,programmers
worked with the most primitive computer instructions,machine
language,These instructions were represented by long strings of
ones and zeros,Soon,assemblers were invented to map machine
instructions to human-readable and manageable mnemonics,
such as ADD and MOV.
自从第一代电子计算机在第二次世界大战中用于自动计算以来, 计算机语
言已发生了巨大的变化 。 早期编程员使用最原始的计算机指令 ——机器语
言来工作 。 这些指令由一长串的 0,1组成 。 不久, 发明了汇编程序, 它能
将机器指令转换成易读, 易管理的助记符, 如 ADD,MOV等 。
7.1 Computer Languages
Chapter 7 Programming Languages
计算机专业英语 7-6
7.1 Computer Languages
In time,higher-level languages evolved [1],such as BASIC and COBOL.
These languages let people work with something appropriating words and
sentences,Such as Let I=100,These instructions were translated back into
machine language by interpreters and compilers,An interpreter translates
a program as it reads it,turning the program instructions,or code,directly
into actions,A compiler translates the code into an intermediary form,This
step is called compiling,and produces an object file,The compiler then
invokes a linker,which turns the object file into an executable program.
随后, 又推出了高级语言, 如 BASIC和 COBOL.。 这些语言使用的是近似于
人常用的词句, 如 Let I=100。 这些指令由解释器或编译器翻译成机器语
言 。 解释器边读边翻译, 将程序指令或代码直接实现 。 编译器把代码翻
译成中间代码 。 这一部叫做编译, 然后生成目标文件 。 编译程序调用链
接程序, 链接程序将目标代码转变成可执行程序 。
Chapter 7 Programming Languages
计算机专业英语 7-7
Ironically,in order to become easier to use for this new audience,
programs have become far more sophisticated,Gone are the
days when users typed in cryptic commands at esoteric prompts,
only to see a stream of raw data,Today’s programs use
sophisticated,user-friendly interfaces,” involving multiple
windows,menus,dialog boxes with which we’ve all become
familiar,The programs written to support this new approach are
farmorecomplexthanthosewritten justten years ago.
为使程序更易于被新用户使用, 程序本身反而变得越来越复杂 。 用户需
在抽象的提示符下键入难于理解的命令, 只能看到一串原始数据的时代
已经一去不复返了 。 如今, 程序使用了复杂的, 友好用户界面,, 包含
我们已很熟悉的多窗口, 菜单, 对话框 。 支持这些新方法的程序比十年
前复杂得多 。
7.1 Computer Languages
Chapter 7 Programming Languages
计算机专业英语 7-8
New Words & Expressions:
object-oriented 面向对象的 ongoing adj,正在进行中的
crisis n,危机 exploit v,开发, 使用
raw adj,天然的, 原始的 medium n,媒介, 方法
match 相称, 匹配 discrete adj,单个的, 离散的
transistor n,晶体管 resistor n,电阻
capacitor n,电容 integration 集成电路
abstraction n,抽象化 class n,类
inheritance n,继承 encapsulation n,封装
polymorphism n,多型 entity n,实例, 实体
7.2 Object-Oriented Programming
Abbreviations,
OOP ( Object-Oriented Programming) 面向对象的编程技术
IC (integrated circuits) 集成电路
LSI( large-scale integration) 大规模集成电路
VLSI( very large-scale integration) 超大规模集成电路
Chapter 7 Programming Languages
计算机专业英语 7-9
7.2 Object-Oriented Programming
Ever since computers became available in the 1950s,it has been
software that exploited its power to solve application problems
[2],Machine code,capable of driving the raw hardware,was the
first language available to programmers,Sequences of code
statements were the earliest form of software,It was soon
recognized that the communication medium between programmer and
computer is a critical factor in the programming productivity and
quality of the overall software product.
自从 50年代计算机开始进入实用阶段以来, 软件就在解决应用问题的能力
方面崭露头角 。 控制基本硬件的机器代码是程序员使用的第一种语言 。 顺
序代码语句是软件的最早形式 。 人们很快就认识到, 编程效率和整个软件
产品质量的关键因素是程序员和计算机之间的通信手段 。
Chapter 7 Programming Languages
计算机专业英语 7-10
7.2 Object-Oriented Programming
While computers,the hardware,underwent revolution after
revolution,using faster and ever more powerful components,the
software technology has significantly lagged behind in matching
these advances,Hardware technology has been revolutionized several
times,from tubes to discrete transistors,resistors and capacitors
to board-level integration to integrated circuits,Even integrated
circuits have undergone several significant evolutionary steps:
from large-scale integration (LSI) technology to very large scale
integration (VLSI),and eventually wafer scale integration.
Hardware engineering was able to keep up with this pace by
developing new techniques to manage the exploding complexity of a
modern computer system.
当计算机硬件由于使用速度更快, 功能更强的器件而不断更新换代的时候, 软件
技术则大大滞后, 与硬件的发展不相匹配 。 硬件技术已经历了几次革命:从电子
管到单个晶体管, 电阻和电容器元件, 到板级集成电路, 到整个集成电路 。 即使
是集成电路也经历了几次重大的演变:从大规模集成电路 (LSI)技术到超大规模集
成电路 (VLSI),并且又发展了晶片上大规模集成技术 。 硬件工程能够保持这种发
展势头, 是因为新技术的发展可以对付现代计算机系统与日俱增的复杂性 。
Chapter 7 Programming Languages
计算机专业英语 7-11
7.2 Object-Oriented Programming
Ever since computers were used to solve application problems,it
was the task of software to bridge the gap between concepts in an
application and computer concepts,Fig,7-1 illustrates this
semantic gap,On one side of the gap are the concepts of an
application,for example,customer files to organize,accounts to
maintain,or rockets to launch,On the other side are the
concepts understood by a computer system,electric impulses,
micro code,machine code instructions,and programming language
constructs,The typical programming task is to translate the
application concepts into computer concepts,If the translation
succeeds and the computer solves the application problem,a
successful software product has been developed.
自从计算机用于解决应用问题以来, 软件的任务就是在应用概念和计算机
概念之间架起一座桥梁 。 图 7-1表示这种语义间隔, 其一端是应用概念, 如
客户文件的组织, 账户的维护或火箭的发射;另一端是计算机系统所理解
的概念, 电脉冲, 微代码, 机器代码指令和程序设计语言结构 。 典型的程
序设计任务是将应用概念翻译成计算机概念 。 如果翻译成功了, 并且计算
机也解决了这个应用问题, 一个成功的软件产品就开发出来了 。
Chapter 7 Programming Languages
计算机专业英语 7-12
7.2 Object-Oriented Programming
Advances in software technology are driven by the desire to make the transition
from application concepts to computer concepts easier,Advances in software
technology have narrowed the gap from both sides,On one side they provided
software design principles and techniques that allow the programmer to express
an application problem closer to computer system terms,Software design
principles,such as abstraction,information hiding,modularization and stepwise
refinement,allow the programmer to conceptualize application concepts and to
ease their transformation into computer system concepts.
希望较容易地把应用概念转变为计算机概念这一愿望推动着软件技术的进步,
这种进步从两端使间隙变窄了 。 在一端,软件技术的进步提供一些 软件设计原
理和技术, 使得程序员用更接近于计算机系统的术语表达应用问题 。 软件设计
原理, 诸如抽象化, 信息隐蔽, 模块化和分段优化, 允许程序员对应用概念概
念化, 从而更容易地将之转变成计算机系统概念 。
On the other side,software technology has advanced the expressive
power of the tools used to manipulate a computer system,the
programming languages.
在另一端, 软件技术的发展使得操纵计算机系统的工具 ——程序设计语言 具有
更强的表达能力 。。
Chapter 7 Programming Languages
计算机专业英语 7-13
7.2 Object-Oriented Programming
In the late 1960s it was recognized that a combination of both forces-
software design technology and advances in programming languages-may be
possible,The resulting language construct was a class,A class implements
the concepts of abstraction,modularization,and data hiding,It does so by
grouping a user-defined type with all procedures and functions that can be
applied to it,Classes allow inheritance,The concept of inheritance relates
to the design concept of stepwise refinement and also allows the reuse of
existing code and data structures in a class.
60年代末, 认识到将两种力量 (即 软件设计技术 和 程序设计语言 的进展 )结
合起来是可能的, 这样形成的语言结构就是, 类, 。 类通过按所有过程和
函数对用户定义的类型进行分组而实现抽象化, 模块化和数据隐蔽的概念 。
类允许继承, 继承的概念与分段优化的设计概念相关并允许重新使用在同
一类中的现有代码和数据结构 。
Chapter 7 Programming Languages
计算机专业英语 7-14
7.2 Object-Oriented Programming
The engineering of a class concept represents a step to software technology
similar to the development of an integrated circuit (IC) to hardware,As new
hardware systems can be built by using (or modifying) off-the-shelf ICs,it is
now possible to build software systems by reusing (or extending) off-the-shelf
classes,"Class" is the central concept in object-oriented programming.
Object-oriented programming promises to significantly narrow the semantic
gap.
类的概念工程象征着朝向软件技术迈开的一步, 类似于集成电路的开发对
于硬件的贡献 。 如同可以通过使用或修改流行的集成电路来做新的硬件系
统一样, 可以重新使用或扩展现有的类去构成软件系统 。, 类, 是面向对
象程序设计的核心概念 。 面向对象的程序设计有望缩小以上所提到的语义
间隙 。
Chapter 7 Programming Languages
计算机专业英语 7-15
7.2 Object-Oriented Programming
Some of the benefits and flexibility of object-oriented programming
stem from this separation of function invocation and implementation.
The invocation of a functionality is termed "the sending of a
message to an object." The execution of its implementation is termed
"the receiver of the message executes the corresponding method." The
separation of message and method greatly adds to the flexibility
possible in an object-oriented program,In our example messages are
sent to the plane objects,Each plane object receives a message and
executes its desired behavior,In effect,our program "computes" by
sending messages to all participating objects,In general,we can
observe an object-oriented program as a collection of objects that
communicate by sending messages.
面向对象的程序设计的一些优点和灵活性源于将功能的引发和实现相互分离这一技
术 。 功能的引发可表达为, 把信息送给对象, 。 实现的过程被称为, 信息接收者执
行相应的方法, 。 信息和方法的分离大大地增加了面向对象程序灵活性 。 在我们的
例子中, 信息是送给飞机对象的, 每一飞机对象接收一个信息并执行其所要求的行
为 。 实际上, 我们的程序通过向所有在场的对象发送信息而进行, 计算, 。 一般来
讲, 我们可以把面向对象的程序看作是通过发送信息进行通信的各个对象的集合 。
Chapter 7 Programming Languages
计算机专业英语 7-16
三, 解环法
这种方法适用于翻译, 连环式, 后置定语或定语从句, 也就是当原文中的
一个中心词 (组 )被若干个定语 (从句 )一环扣一环地修饰时, 可先将中心词
(组 )译出, 或把中心词 (组 )与靠近它的一个或两个后置定语 (从句 )译成汉语
偏正词组, 然后顺着, 修饰环, 依次翻译其余成分 。
采用这种方法译出的句子层次分明,脉络清楚 。 由于科技英语中, 连环式,
修饰语出现较多, 所以, 解环法, 具有较大的实用价值 。 例如,
A flight simulator is a perfect example of programs that create a virtual
reality,or computer-generated,reality” in which the user dose not merely
watch but is able to actually participate.
译文,飞行模拟器是创造虚拟现实的程序的一个完美例子, 或者也可以叫
它计算机生成的, 现实,, 在这个, 现实, 中, 用户不仅能看, 而且能实
际参与 。
(比较:飞行模拟器是创造虚拟现实, 或者也可以叫它计算机生成的, 用
户不仅能看, 而且能实际参与的, 现实, 的程序的一个完美例子 。 )
复杂定语 (从句 )的翻译技巧之二
Chapter 7 Programming Languages
计算机专业英语 7-17
复杂定语 (从句 )的翻译技巧之二
三, 解环法
再如,Object-oriented databases store and manipulate more complex data
structures,called,object”,which are organized into hierarchical classes that
may inherit properties from classes higher in the chain; this database
structure is the most flexible and adaptable.
译文,面向对象的数据库可以存储并处理更加复杂的数据结构, 这种数据
结构称为, 对象,,, 对象, 可以按层次组成, 类,, 低层的, 类, 可以
继承上层, 类, 的属性;这是一种最灵活, 最具适应性的数据结构 。
(比较:面向对象的数据库可以存储并处理更加复杂的, 称为, 对象, 的,
可以按层次组成, 类, 的, 低层的, 类, 可以继承上层, 类, 属性的数据
结构;这是一种最灵活, 最具适应性的数据结构 。 )
在英语科技文献中, 对于某些连环式修饰语, 有时还需同时借助, 先提后
叙法,, 才能使语句顺畅 。 例如,
Chapter 7 Programming Languages
计算机专业英语 7-18
复杂定语 (从句 )的翻译技巧之二
It (chapter 2) provides numerous solutions for protecting problems
associated with any type of instruments using microprocessors that must be
protected when voltage supply fluctuates.
此句属连环式修饰 。 由于各个修饰环扣得很紧 ?? 原文中, protecting
problems 并非仅仅与 associated with … instruments有关, (定语从句本身
带有一个较长的状语 )。 因此, 译成汉语时, 为了使修饰成分紧扣修饰对
象, 既不宜直接译成偏正词组 ?? 这会造成, 大肚子, 句, 见译文 (1);也
不宜用, 解环法, 法逐个翻译修饰环 ?? 这会导致修饰语与中心词关系松
弛, 见译文 (2)。 此时可采用, 解环法 +先提后叙法,, 也就是先译出一两
个修饰环, 再用, 这样的,,, 这样一些, 等词语, 扣, 住中心词, 最后
叙述具体修饰内容 。 这样, 不但句子修饰关系明确, 而且行文较为流畅,
见译文 (3)。
(1) 第二章提供与使用当供电电压波动时必须加以保护的微处理器的任
何类型仪器有关的保护问题的许多解决办法 。
(2) 第二章提供与任何类型仪器有关的保护问题的许多保护办法, 这类
仪器使用微处理器, 这些微处理器当供电电压波动时必须予以保护 。
(3) 第二章提供解决某些保护问题的许多办法, 这些保护问题与任何使
用这样一些微处理器的仪器有关:当供电电压波动时时, 必须予以保护 。
Chapter 7 Programming Languages
计算机专业英语 7-19
复杂定语 (从句 )的翻译技巧之二
三, 解环法 +先提后叙法
例句, This is a software of flight simulator running on
personal computers,intended primarily for computer-aided
instruction which requires providing practice navigation and
instruments reading while users immerse in the virtual
environment.
这个句子中的修饰关系也是, 连环式, 。 由于某些修饰环 (如 of … 和
running …,intended … 和 which … )扣得紧, 加上 which引导的定语
从句本身含有一个 while 引导的状语从句, 所以此句也适于采用, 解环
法 +先提后叙法, 。 全句可译为:
这是一个运行于个人计算机的飞行模拟器软件, 这种软件主要用于如
下计算机辅助教学:当用户投入虚拟环境时, 它必须提供导航和仪表读
数 。
由此可见, 翻译, 连环式, 修饰成分要因句制宜, 灵活处理, 不能只
着眼于表面的修饰关系, 还要考虑, 修饰环, 之间的紧密程度 。 通常,
如果, 修饰环, 彼此关系较松, 适于采用, 解环法, ;要是, 扣, 得很
紧, 则可采用, 解环法 +先提后叙法, 。
Chapter 7 Programming Languages
计算机专业英语 7-20
复杂定语 (从句 )的翻译技巧之二
四, 句子结构调整法
有时, 原文句中一个中心词带有若干修饰成分, 但它们既不是纯, 并列,
头系, 也不是规则的, 连环, 关系, 而是, 并列, 中有, 连环, (例 1),
或, 连环, 中含不规则, 修饰环, (例 2);或者句中各有一个分别被, 连
环式, 定语和, 并列式, 定语所修饰的中心词 (例 3);或者中心词的定语
从句本身又含有其他修饰成分 (例 4)。 由于这类句子所含的修饰关系比较
复杂, 很难纳入上述几种译法予以表达, 此时就应该根据上下文的逻辑
关系, 调整句子结构 。 常用的方法是:, 化整为零,, 将带有多重定语
(从句 )的长句拆译成若干汉语短句, 然后按汉语表达习惯组织译文句子 。
例如,
例 1,An operating system is a master control program,permanently
stored in memory,that interprets user commands requesting
various kind of service,such as display,print,or copy a
data file,list all files in a directory,or execute a
particular program.
译文,操作系统是主控程序, 永久地驻留在内存中, 它理解用户的各种指令:
如显示, 打印文件, 将目录中所有文件列表, 或者执行一个特殊的程序 。
(比较:操作系统是永久地驻留在内存中的;理解用户的各种指令:如显示,
打印文件, 将目录中所有文件列表, 或者执行一个特殊的程序主控程
序 。 )
Chapter 7 Programming Languages
计算机专业英语 7-21
复杂定语 (从句 )的翻译技巧之二
? 例 2,The users of such a system control the process by means of a
program,which is a set of instruction that specify the operation,
operands,and the sequence by which processing has to occur.
? 译文:该系统用户通过程序控制处理过程, 所谓程序是一套指定操作, 操作数和处
理序列的指令集 。 (比较:该系统用户通过一套指定操作, 操作数和处理序列的指令
集即程序控制处理过程 。 )
? 例 3,Indeed,today's products -- most of all,the latest in speech
recognition – are a roll-out of technologies that have been
percolating for years and that are based on an understanding of
speech that has taken several decades to accumulate.
? 译文:的确, 今日的产品, 尤其是语音识别方面最新的产品, 是过去多年技术渗透
的延伸, 也是基于几十年来对语音理解的结果 。
? (比较:的确, 今日的产品, 尤其是语音识别方面最新的产品, 是过去多年的渗透和
基于几十年来对语音理解的积累的技术延伸 。 )
? 例 4,The computer family,in computer science,is a term commonly
used to indicate a group of computers that are built around the same
microprocessor or around a series of related microprocessors,and
that share significant design feature.
? 译文:在计算机科学中, 计算机系列是常用的一个术语, 通常指一组用相同的或者
一系列相关的微处理器制造的计算机 。