School of System and Technology: Department of Computer Science
School of System and Technology: Department of Computer Science
Assignment-1
Q2: For each of these sentences, determine whether an inclusive or, or an exclusive or, is
intended. Explain your answer.
a) Coffee or tea comes with dinner.
b) A password must have at least three digits or be at least eight characters long.
c) The prerequisite for the course is a course in number theory or a course in cryptography.
d) You can pay using Pak rupees or U.S. dollars.
e) Experience with C++ or Java is required.
f) Lunch includes soup or salad.
g) To enter the country you need a passport or an ID card.
Q3: Construct the Truth Tables of the following Implications and compound
propositions. Show if it is logically equivalent, Tautology, contradiction or
contingency.
Sr. No Expressions
1 p → q ≡ ¬p ∨ q
2 ¬(p ∨( ¬p ∧ q)) ≡ ¬p ∨ ¬q
3 p ∧ q ≡ ¬(p →¬q)
4 p ∨ (q ∧ r) ≡ (p ∨ q) ∧ (p ∨ r)
5 (p → q) ∧ (p → r) ≡ p → (q ∧ r)
6 (p → r) ∨ (q → r) ≡ (p ∧ q) → r
7 p ꚛ q ≡ (p ∨ q) ∧ ¬(p ∧ q)
Instructions:
1. Each expression should be clearly mentioned with its given number.
2. Make Tables with proper Table numbers to show truth tables for each expression like
there are 10 expressions, you should have 10 Tables.
3. Make a Title page and mention your details (including Name, Registration no.
Section ID, Title of the assignment etc.).
4. Don’t copy from others.
5. Submit your assignment to the LMS in MS-word or PDF format.
6. Deadline can be checked on your LMS.