CS350 - Final Examination - Review Questions - Spring 2003


Examples of Specific problems

Show the parse tree for the derivation of _______ based on the following grammar.

Consider the following grammar _________. Which of the following sentences can be generated by this grammar.

Write a grammar that generates sentences like ________________.

Is the grammar _______________ ambiguous.

List (2,3,4,5,...) attributes of the (ADA, Fortran, Pascal, Cobol, Basic, SmallTalk, C++) language.

Describe the attributes of a recursive descent parser.

Compare and contrast a static versus a dynamic-scoped language.

Describe a mechanism that can be used to control concurrency.

What is deadlock?

Describe and give an example of a race condition.

What is an exception handling technique available in Java and C++? Describe its use.

Given the definition of a turing machine (_______), determine is the following phrase is accepted by the machine.

Concerning arrays, compare and contrast allocation using of static, stack dynamic and heap dynamic.

Give an example of a side-effect in a programming language of your choice.

Discuss the use of short-circuiting in programming languages. Discuss some difficulties that it may cause.

Should the "goto" statement be eliminated from all programming languages? Why or why not.

Give examples of what happens when we use parameter passing: pass-by-value, pass-by-reference, pass-by-value-result, pass-by-name.

Briefly discuss the use of activation records.

What is an ADT? Why are they used.

Describe the use of polymorphism and give an example.

Why might a programming language use message passing?

What is garbage collection? What are some languages that use garbage collection?

Describe deadlock? Discuss some schemes for avoiding deadlock.

What is a semaphore? What is a monitor? Discuss how and why they are used.

Describe the use of the try, throw and catch construct.

Evaluate the following LISP statement ________________________.