

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
A collection of questions from the fall 2004 final examination of the computer science department at an unspecified university. The questions cover various topics in computer science, including logic, algebra, probability, combinatorics, and graph theory.
Typology: Exams
1 / 2
This page cannot be seen from the preview
Don't miss anything!


CMSC 203 Fall 2004 Final Examination
2. Negate: Some integers are perfect squares and odd..
3. Find the Contrapositive form of: All dogs that run fast have long legs.
4. Find the Big-O of the algorithm with complexity:
(3 x^6 + 4 x^3 + 1)( x^4 + 2 x ) + (3 x^7 + 7 x^3 + 2)(2 x^3 ).
5. What is the probability that a binary string of length 10 will have no more than three 1’s?
6. How many ways can I fill a cooler with cans of soda if the cooler holds 60 cans, I have 8 different types of soda, and I want at least 4 of each type in the cooler?
7. Graph the relation R = {( a,b ) | a,b ∈ {0, 1, 2, 3, 4, 5, 6, 7} and b = [( a^2 − 2) mod 5]}.
9. Let f = {(1,3), (2,2), (3,4), (4,5), (5,1)}, g = {(1,4), (2,5), (3,1), (4,2), (5,3)}, and h = {(1,5), (2,4), (3,3), (4,2), (5,1)}. Find h o g o f.
10. Find the Disjunctive Normal Form of the Boolean Expression that describes a 3-way light switch controlling a lightbulb that INCLUDES the case of being ON when the first two switches are ON and the third is OFF.
11. Find the next 5 terms of s n = 2s n − 1 − 3s n − 2 when s 0 = (−1) and s 1 = 1.
12. How many ways can I line up 5 Pennies, 2 Nickels, 4 Dimes, 3 Quarters, and 6 Half-dollars, if all the coins are from the same year? (e.g. HQHDNDHQHDNQDHH)
13. Let E and F represent event sets within the sample space S. If there is a 50% probability of E occurring within F and there is a 50% probability of F occurring within S, show the E is indepen- dent of F.
14. Graph an examples of: (a) an Onto function that is NOT One-To-One. (b) a One-To-One function that is NOT Onto.
Docsity.com
15. Prove one of the following theorems by Induction:
Theorem: For all Integers n > 0 and a ≠ 0,1,.
Theorem: If a 1 , a 2 , a 3 , ... is the sequence: a 0 = 3, a 1 = 5, a 2 = 7 with a (^) n = a (^) n − 1 + an − 2 + a (^) n − 3 ,
then a (^) n is odd for all n ≥ 3.
16. Prove one of the following theorems by Contradiction:
Theorem: is irrational. Theorem: If every integer is divisable by a prime, then the set of primes is infinite.
17. Prove one of the following theorems: Theorem: If f(x) = 4 x + 8, then R = {( x,y ) | x,y ∈ R and f(x) = f(y) } is an Equivalence Relation. Theorem: If f(x) = 4 x + 8, then f is a Bijection from R to R.
a i i = 0
n
a n^ +^1 – 1 a – 1
= ---------------------
2
Docsity.com