Monday, March 25, 2013

Concepts of Programming Languages - Chapter 1


Review Questions

3. What programming language has dominated scientific computing over
the past 50 years?
Fortran

4. What programming language has dominated business applications over
the past 50 years?
COBOL

5. What programming language has dominated artificial intelligence over
the past 50 years?
LISP

6. In what language is most of UNIX written?
C

21. What two programming language deficiencies were discovered as a
result of the research in software development in the 1970s?
Incompleteness of type checking and inadequacy of control statements

22. What are the three fundamental features of an object-oriented programming
language?
Encapsulation, inheritance, polymorphism

23. What language was the first to support the three fundamental features of
object-oriented programming?
Smalltalk

25. What are the three general methods of implementing a programming
language?
Compilation, pure interpretation, hybrid implementation system

26. Which produces faster program execution, a compiler or a pure
interpreter?
A compiler

29. Whhat is a hybrid implementation system?
An implementation that translates high-level language programs to an intermediate language designed to allow easy interpretation so that it is faster than pure interpretation because the source language statements are decoded only once.


Problem Set

1. Do you believe our capacity for abstract thought is influenced by our
language skills? Support your opinion.
Yes, because by having programming language skills we know the differences of the languages and we can choose which kind of language that is more suitable to the algorithm we are making so the algorithm will be a simple one.

2. Who is said to be the first programmer in human history? Use the Internet for help.
Ada Lovelace

4. In what way do the languages for scientific applications differ from the languages for business applications? Support your view.
Scientific applications used relatively simple data structures but required large numbers of floating-point arithmetic computations. Business languages are characterized by facilities for producing elaborate reports, precise ways of describing and storing decimal numbers and character data, and the ability to specify decimal arithmetic operations.

7. Java uses a semicolon to mark the end of all statements. What are the advantages for and against this design?
Adv: using semicolon is a simplicity that it closes every statement.
Disadv: sometimes we forget to put semicolon on a statement that it creates compilation error.

10. Make a comparative study of the cost of software and hardware.
The cost of hardware was higher than software in the past, but now they're the opposite.

12. Can we call any programming language complete, in your opinion? Why or why not?
No, because each programming language has its own characteristics and is used for a specific purpose that differs it from other programming languages


Edited on 25/03/2013

No comments:

Post a Comment