1. Prof. Lennart Van der Zeil’s theorem says that any programming language is complete if it can be used to write a program to compute any computable number.
a. What is a computable number?
b. What is a non-computable number?
c. If all existing programming languages are complete why do we need more than one?
2. Two methodologies are used to transform programs written in a source language (also known as a programmer-oriented language, or a horizontal language, or a high-level language) into a target language (also known as a machine language, or a vertical language, or a low-level language). There is a static method called translation and a dynamic method called interpretation. Yet FORTRAN while 98% static ., uses interpretation for the Formatted I/O statement, similarly COBOL uses interpretation for the MOVE and MOVE CORRESPONDING statements; on the other hand, Java is fully interpretative except that in some programs and certain data sets it may invoke a JIT (Just In Time) compiler to execute a bit of static code. Why do language designers mix these modalities if either is complete? Hint: This is a long question with a short answer.
3. C and C++ store numerical arrays (matrices) in row major order and each index range must begin with 0; whereas FORTRAN stores arrays in column major order and the (default) index range starts (almost always) with 1. Engineers and scientists are often faced with the problem of converting a working program, or much more often a subroutine, from one language to another. Unfortunately, due to the index range difference (0 to n-1) in C/C++ and (1 to N) in FORTRAN, viewing one array as simply the transpose of the other will not suffice. What steps would you take to convert such a subroutine to compute the product of two matrices A(N,M) and B(M,N) to produce C(N,N) from FORTRAN to C++?
4. What was the major reason Jim Gosling invented Java? Did he succeed?
5. What are the four major features of C++ that were eliminated in Java? Why were they taken out? Why do we not miss them?
6. What was Kim Polese’ role at SUN Microsystems and why did she think Java should be positioned as a general purpose computer programming language? How did she accomplish this truly incredible feat, not done since Captain (later Admiral) Grace Murray Hopper, USN standardized COBOL in the early 1960s.
7. Describe briefly the role of women in the development of computer programming and computer programming languages. (Ada Lovelace, Betty Holberton, Grace Hopper, Mandaly Grems, Kim Polese, Laura Lemay)
8. What are the pros and cons of overloaded operators in C++? Java has only one, what is it?
9. State your own arguments for allowing mixed mode arithmetic statements. (See Ch 7)
10. What is BNF and why are meta-languages like BNF and EBNF used?