15-251: Great Theoretical Ideas in Computer Science
Homework 4 (due Thursday, February 23)
Directions: Write up carefully argued solutions to the following problems. The rst task is to be complete and correct. The more subtle task is to keep it simple and
1. Not Pirates and Not Gold
(a) In lecture we developed a solution to this question:
How many nonnegative integer solutions are there to the equation
x1 + x2 + x3 + x4 + x5 = 40
Solution: This is just pirates and gold with n = 40, k = 5. Thus, the answer
15-251: Great Theoretical Ideas in Computer Science
Lecture 1010
Challenge (to work on during lecture)
for those of you who know it all
already:
Probability 1
Construct four dice (where each face has a
number between 1 and 9). Call these dice A, B, C,
and
CMU 15-251
Spring 2017
Homework 1
Writing session on Wednesday January 25
0. (SOLO) Read very carefully the course policies on the course webpage http:/www.cs.cmu.
edu/~./15251/policy.html. This is a required component of the course. You will be asked
to
15-251: Great Theoretical Ideas In Computer Science
Homework 4 Solutions
Prelude:
After destroying the evil SHRDLU, all the sleeping people on earth woke up. The TAs were so proud
of their splendid accomplishment that they decided to spend all their money
15-251: Great Theoretical Ideas In Computer Science
Homework 8: Kingdome Maths
(due 23:59 Wednesday, March 19)
Directions: Write up carefully argued solutions to the following problems. The rst task is to be complete and correct. The more subtle task is t
1. Problem 1
Let L1 L2 .
(a) If L1 is a regular language, then is L2 necessarily a regular language?
Solution:
(b) If L2 is a regular language, then is L1 necessarily a regular language?
Solution:
2. Problem 2
Consider a regular language L that accepts a
1. Axiomatic Systems
Youre a military commander and your intelligence sta has intercepted some enemy
communications. Theyve determined that all of the messages the enemy sends are
strings in the set cfw_+, . Theyve also gleaned that every message s that
15-251: Great Theoretical Ideas In Computer Science
Homework 7 Solutions
Prelude: Much that once was is lost; for none now live who remember it. It began with the forging
of the great rings: three for the Elves, immortal, wisest and fairest of all beings.
15-251: Great Theoretical Ideas In Computer Science
Homework 5: DragonBall Graph Theory Solutions
(due 23:59 Monday, February 17)
Directions: Write up carefully argued solutions to the following problems. The rst task is to be complete and correct. The mo
15-251: Great Theoretical Ideas In Computer Science
Recitation 1 Solutions
Golden AdminisRetriever
Hw2 is due Thursday midnight now because of duplicate problem! Woof!
We are trying very hard to get your hw1 graded and handed back before hw2 is due! (we
15-251: Great Theoretical Ideas In Computer Science
Recitation 3 Solutions
Administration of Champions
HW3 is due Wednesday night! Not Thursday!
Does Winning the Olympics Even Count
Partition: If A is the disjoint union of B and C, |A| = |B| + |C|.
Pro
15-251: Great Theoretical Ideas In Computer Science
Homework 13 Solutions
0.No More Skcirbs! (15 points)
Wandering around, you nd yourself in Bricksburgh. You decide that in order to gure out what on
earth is going on, you should talk to President Tepper.
15-251: Great Theoretical Ideas In Computer Science
Recitation 1 Solutions
Hopefully puzzle hunt is going well. If you have not started.start.
Just as a reminder, the website to submit hunt problems closes (and TA activities stop) at 11:59 PM
Tuesday and
15-251: Great Theoretical Ideas In Computer Science
Homework 12 Solutions
Problems you can assume are NP-complete for this homework:
3-COLOR (Given a graph G, is it 3-colorable?)
CIRCUIT SAT (Given a circuit, can you give some assignment to the inputs t
15-251: Great Theoretical Ideas In Computer Science
Recitation 3 Solutions
Doglympic Rules
Cominatorial Games: A combinatorial game is a two-player game where there is a game state both
players can see with well-dened rules that govern when players can ma