Activities: Review Assembly/Machine Language
and Interpret A Circuit
Diagram
(If you want to write up your answers using Markdown,
here is a template
you can use to get started.
If you want to see your work formatted nicely, install a Markdown
previewer for Brackets or for your browser.)
PART 1: Assembly Language and Machine Language (Review)
- Consider the following tasks: (1) adding 100 numbers stored in
main memory, and (2) adding a number to itself 100 times. Although
both tasks require 100 additions, the second would be executed much
more quickly than the first would. Why?
(Think about the steps you would need to do to program each of these tasks
in assembly/machine language.)
- Describe at least one advantage of assembly languages over machine
languages.
- Describe two advantages of high-level language programming over
machine language programming.
PART 2: Truth Tables and Circuits
The next two questions refer to the following circuit diagram:
- Provide the Boolean formula (in terms of
a
and
b
) for the output z
in the circuit
diagram above.
- Provide a truth table that shows the inputs
a
and
b
and the
output z
corresponding to the circuit diagram above.
* Some of these questions are taken from A Balanced Introduction to
Computer Science, David Reed, 2005.