CS 680
Spring, 2003
Ethan Bolker
Midsemester Exam
April 9, 2003
This exam is an experiment. The good news is that
rather than asking a few highly specific
questions to probe your ignorance,
I've formulated general questions that
give you the best chance to
tell me things you've learned. The bad news is that you have a greater
responsibility to use your time wisely, spending it on ideas that you
think are really important.
Attached you will find a Java solution to the ticket system you have
just completed in C++. It works - that is, it meets the specifications
- but it's a terrible solution - full of bad
smells. (I had to hold my nose to write it.)
-
Draw a UML sequence diagram illustrating what happens to make this
output appear (assume the ticket in question is already in the queue
and is next to be served).
ts-login> operator
Ticket 4
submitted: Wed Apr 09 10:09:13 EDT 2003
by: eb
priority: high
second high priority ticket - should be served second
closed: Wed Apr 09 10:09:14 EDT 2003
-
Study the code. Jot down some notes to yourself about the parts of the
design you don't like. Then discuss what you would do to refactor it.
I will judge your answer in part on the significance of the
issues you choose to address and the strategies you suggest, including
the order in which you would plan to make changes.
-
Discuss how the differences between C++ and Java influence the
design and implementation of the ticket system.
-
Choose one short subject we studied this semester that
you haven't yet discussed on this exam,
invent a question about it and answer your question.