Assignment 1, due Sep 1Solutions
Part of
the homework for CS:2820, Fall 2017

Background: Consider these two Java declarations:
int i = 1 + 'a'; String j = "a" + 1;
a) What operation does the + operator do on the first line? (0.3 points)
b) What is the resulting value of i? (0.2 points)
c) What operation does the + operator do on the second line. (0.3 points)
d) What is the resulting value of j? (0.2 points)
a) Give the truth table for the 2input function called a or not b. (0.3 points)

b) What is the function number of the function in part a in the table of 16 functions. (0.2 points)
c) Give the truth table for the 2input function called a and not b. (0.3 points)

d) What is the function number of the function in part c in the table of 16 functions. (0.2 points)
Consider the problem of modeling the University of Iowa pentacrest, with these streets if we ignore the complexity of the bus interchange:
These streets also play a part, some only because they add intersections to the model:
Wherever 2 lanes go the same direction between intersections, lane changes are allowed.
A problem: Draw a diagram, with points for every intersection and arrows connecting the points showing how this road network would be modeled. Include both real intersections and the intermediate intersections that must be added in order to model lane changes. The arrow head on each "road" indicates the direction of travel on that road.
Legibility matters. Lay out your diagram with north on the top and try to keep the topology the same as the real road network. Exact scale does not matter, but You might start by using a blowup of a map as a layout guide (there are plenty of online map services). If your drawing skills are horrible, you may have to redraw a few times to get legible results.
The parts of the above table shown in light grey are outside the scope of the assignment and given only because they provide context for what was required here. The midblock intersections that join two parallel "roads" going in the same direction represent the opportunity to change lanes in midblock between two real intersections.