# Discrete Mathematics MCQ

1) If x is a set and the set contains an integer which is neither positive nor negative then the set x is ____________.

1. Set is Empty
2. Set is Non-empty
3. Set is Finite.
4. Set is both Non- empty and Finite.

Answer: d) Set is both Non- empty and Finite.

Explanation: The non-empty and finite set is set {0}.

2) If x ∈ N and x is prime, then x is ________ set.

1. Infinite set
2. Finite set
3. Empty set
4. Not a set

Explanation: There is no extreme prime, so the number of primes is infinite.

3) If x is a set and the set contains the real number between 1 and 2, then the set is ________.

1. Empty set
2. Finite set
3. Infinite set
4. None of the mentioned

Explanation: X is an infinite set as there are infinitely many real numbers between 1 and 2.

4) Which of the following is a subset of set {1, 2, 3, 4}?

1. {1, 2}
2. {1, 2, 3}
3. {1}
4. All of the mentioned

Answer: d) All of the mentioned

Explanation: The subset of set (1, 2, 3, 4} is {1, 2}, {1, 2, 3}, and {1}.

5) Convert the set x in roster form if set x contains the positive prime number, which divides 72.

1. {∅}
2. {2, 3}
3. {2, 3, 7}
4. {3, 5, 7}

Explanation: 2 and 3 are the divisors of 72, which are prime. So, the roster form of set x is (2, 3}.

6) Power set of empty or Null set has exactly _________ subset.

1. One
2. Two
3. Zero
4. Three

Explanation: The power set of the Null set has exactly one subset, which is an empty set.

7) What is the Cartesian product of set A and set B, if the set A = {1, 2} and set B = {a, b}?

1. { (1, a), (1, b), (2, a), (b, b) }
2. { (1, 1), (2, 2), (a, a), (b, b) }
3. { (1, a), (2, a), (1, b), (2, b) }
4. { (1, 1), (a, a), (2, a), (1, b) }

Answer: c) { (1, a), (2, a), (1, b), (2, b) }

Explanation: A subset R of the Cartesian product A x B is a relation from the set A to the set B.

8) The members of the set S = {x | x is the square of an integer and x < 100} is ________________

1. {0, 2, 4, 5, 9, 55, 46, 49, 99, 81}
2. {1, 4, 9, 16}
3. {0, 1, 4, 9, 16, 25, 36, 49, 64, 81}
4. {0, 1, 4, 9, 25, 36, 49, 123}

Answer: c) {0, 1, 4, 9, 16, 25, 36, 49, 64, 81}

Explanation: The set S contains the square of an integer less than 10. That's why the third option is correct according to the given set.

9) The intersection of the sets {1, 2, 8, 9, 10, 5} and {1, 2, 6, 10, 12, 15} is the set _____________

1. {1, 2, 10}
2. {5, 6, 12, 15}
3. {2, 5, 10, 9}
4. sd) {1, 6, 12, 9, 8}

Explanation: The intersection of the two sets is the set that contains the common elements of both the given sets. That's why the first option is right according to the given sets.

10) The difference of {1, 2, 3, 6, 8} and {1, 2, 5, 6} is the set ____________

1. {1, 3}
2. {5, 6, 8}
3. {3, 8}
4. {2, 6, 5}

Explanation: The 'difference of the sets A and B' (A-B) is the set that contains the elements that are in set A but not in set B.

11) If n(A) = 20 and n(B) = 30 and n(A U B) = 40 then n(A ∩ B) is?

1. 20
2. 30
3. 40
4. 10

Explanation: By using the formula we can calculate n(A ∩ B),

n(A U B) = n(A) + n(B) - n(A ∩ B).

n(A ∩ B) = n(A) + n(B) - n(A U B)

n(A ∩ B) = 20 + 30 - 40

So, n(A ∩ B) = 10

12) Let the players who play cricket be 12, the ones who play football 10, those who play only cricket are 6, then the number of players who play only football are ___________, assuming there is a total of 16 players.

1. 16
2. 8
3. 4
4. 10

Explanation: None

13) Which among the following can be taken as the discrete object?

1. People
2. Rational numbers
3. Integers
4. All of the mentioned

Answer: d) All of the mentioned

Explanation: Discrete object includes people, houses, rational numbers, integers, automobiles.

14) Which option contains two equal sets?

1. X = {5, 6} and Y = {6}
2. X = {5, 6, 8, 9} and Y = {6, 8, 5, 9}
3. X = {5, 6, 9} and Y = {5, 6}
4. X = {5, 6} and Y = {5, 6, 3}

Answer: b) X = {5, 6, 8, 9} and Y = {6, 8, 5, 9}

Explanation: The second option is true because both X and Y sets have the same elements.

15) The cardinality of the Power set of the set {1, 5, 6} is______________.

1. 5
2. 6
3. 8
4. 10

Explanation: The power set of the any set is the set of all its subset. So, P({1, 5, 6}) = {null, {1}, {5}, {6}, {1, 5}, {1,6}, {5, 6}, {1, 5, 6}}. The power set of the given set consists of 8 elements. That's why, 8 is the cardinality of the given set.

16) The Cartesian product of the (Set Y) x (Set X) is equal to the Cartesian product of (Set X) x (Set Y) or Not?

1. Yes
2. No
3. None of the above
4. I Don't know

Explanation: The Cartesian product of the (Set Y) x (Set X) is not equal to the Cartesian product of (Set X) x (Set Y).

Let's suppose X = {5, 6, 7} and Y = {a, b, c}. The Cartesian product of (set X) x (set Y) = {(5, a), (5, b), (5, c), (6, a), (6, b), (6, c), (7, a), (7, b), (7, c) } and the Cartesian product of (set Y) x (set X) = {(a, 5), (a, 6), (a, 7), (b, 5), (b, 6), (b, 7), (c, 5), (c, 6), (c, 7)}. So, both the Cartesian product are not equal.

17) How many elements in the Power set of set A= {{Φ}, {Φ, {Φ}}}?

1. 4 elements
2. 2 elements
3. 6 elements
4. 5 elements

Explanation: Set A contains two elements. So, the number of elements in the power set of Set A is 4.

18) Mathematics can be broadly categorized into how many types?

1. 3 types
2. 2 types
3. 5 types
4. 4 types

Explanation: Mathematics can be broadly categorized into Continuous and Discrete Mathematics.

19) Which of the following function is not a mathematics function?

1. many to one
2. one-to-many
3. one to one
4. All of the mentioned

Explanation: None

20) Which of the following function is also referred to as an injective function?

1. Many-to-one
2. Onto
3. One-to-One
4. None of the mentioned

Explanation: An injective function or one-to-one function is a function that connects a single element of domain to the single element of co-domain.

21) How many injections are defined from set A to set B if set A has 4 elements and set B has 5 elements?

1. 24
2. 64
3. 144
4. 120

Explanation: 120 injections are defined from set A to set B if set A has 4 elements and set B has 5 elements. Using the following formula, we can easily calculate the injections:

Number of injections from set A to Set B= 5p4

5! / (5 - 4)! = 5 x 4 x 3 x 2 = 120

22) The function (gof) is _________ , if the function f and g are onto function?

1. Into function
2. one to one function
3. onto function
4. one-to-many function

Explanation: The function (gof) is also an '"Onto function" if the function f and g are '"Onto function'.

23) How many bytes are needed for encoding 2000 bits of data?

1. 5 Byte
2. 2 bytes
3. 4 bytes
4. 8 bytes

Explanation: Only 2 bytes are required for encoding the 2000 bits of data.

24) The cardinality of the set of even positive integers less than 20 is__________?

1. 8
2. 10
3. 9
4. 12

Explanation: The cardinality of the set of even positive integers less than 20 is 9, because the set contains 9 elements. The nine elements in set are 2, 4, 6, 8, 10, 12, 14, 16, 18.

25) If X = {2, 8, 12, 15, 16} and Y= {8, 16, 15, 18, 9} then union of X and Y is___________.

1. {2, 8, 12, 15, 16}
2. { 8, 16, 15}
3. {8, 16, 15, 18, 9}
4. {2, 8, 9, 12, 15, 16, 18}

Answer: d) {2, 8, 9, 12, 15, 16, 18}

Explanation: From both the given sets X and Y, 8, 16, and 15 should be taken once because these elements are common to both sets. So the correct union of X and Y is {2, 8, 9, 12, 15, 16, 18}.

26) What is Floor function?

1. It maps the real number to the greatest previous integer
2. It maps the real number to the smallest previous integer
3. It maps the real number to the smallest following integer
4. None of the mentioned

Answer: a) It maps the real number to the greatest previous integer

Explanation: Floor function f(x) maps the real number x to the greatest integer, which is not more than the value of x.

27) What is Ceil function?

1. It maps the real number to the greatest previous integer
2. It maps the real number to the smallest previous integer
3. It maps the real number to the smallest following integer
4. None of the mentioned

Answer: c) It maps the real number to the smallest following integer.

Explanation: Floor function f(x) maps the real number x to the smallest integer, which is not less than the value of x.

28) What is the value of Floor(8.4) + Ceil(9.9)?

1. 18
2. 19
3. 20
4. 17

Explanation: The value of Floor(8.4) + Ceil(9.9) is 18, because the value of Floor(8.4) is 8 and the value of Ceil(9.9) is 10. so, 8+10 is equaled to 18.

29) If a and b are two positive numbers that are less than one, then the maximum value of Floor(a+b) and Ceil(a+b) is?

1. Floor(a+b) is 0 and Ceil(a+b) is 1.
2. Floor(a+b) is 1 and Ceil(a+b) is 0.
3. Floor(a+b) is 1 and Ceil(a+b) is 2.
4. Floor(a+b) is 2 and Ceil(a+b) is 1

Answer: c) Floor(a+b) is 1 and Ceil(a+b) is 2.

Explanation: According to the question, a<1 and b<1, which means that the maximum value of Floor(a+b) is 1 and Ceil(a+b) is 2.

30) How many relations exist from set X to set Y if the set X and set Y has 7 and 8 elements?

1. 256
2. 272
3. 356
4. 56

Explanation: From set X to set Y, there are 2mn number of relations, where m is the elements of set X, and n is the elements of set Y. So, 27 x 8 = 256.

31) The number of reflexive closure of the relation {(0,1), (1,1), (1,3), (2,1), (2,2), (3,0)} on the set {0, 1, 2, 3} is________.

1. 36
2. 8
3. 6
4. 26

Explanation: None

32) The number of transitive closure exists in the relation R = {(0,1), (1,2), (2,2), (3,4), (5,3), (5,4)} where {1, 2, 3, 4, 5} ∈ A is__________.

1. {(0,1), (0,2), (1,2), (2,2), (3,4), (5,3), (5,4)}
2. {(0,0), (4,4), (5,5), (1,1), (2,2), (3,3)}
3. {(0,1), (1,2), (2,2), (3,4)}
4. {(0,1), (5,3), (5,4), (1,1), (2,2)}

Answer: a) {(0,1), (0,2), (1,2), (2,2), (3,4), (5,3), (5,4)}

Explanation: None

33) Which statement is incorrect if X and Y are the two non-empty relations on the set S.

1. If X and Y are transitive, then the intersection of X and Y is also transitive.
2. If X and Y are reflexive, then the intersection of X and Y is also reflexive.
3. If X and Y are symmetric, then the union of X and Y is not symmetric.
4. If X and Y are transitive, then the union of X and Y is not transitive.

Answer: d) If X and Y are transitive, then the union of X and Y is not transitive.

Explanation: None

34) Which option is the negation of the bits "1001011"?

1. 11011011
2. 10110100
3. 0110100
4. 1100100

Explanation: The negation of the given bits is the opposite value of the bits. If the value of a bit is 1 then its negation value is 0. And, if the value of a bit is 0, then its negation value is 1. That's why the negation of "1001011" is "0110100".

35) What is the output of X (Ex-or) Y, if the bits of X is 001101 and the bits of Y is 100110?

1. Output of X (Ex-or) Y is 101011
2. Output of X (Ex-or) Y is 1101010
3. Output of X (Ex-or) Y is 101000
4. Output of X (Ex-or) Y is 0010101

Answer: a) Output of X (Ex-or) Y is 101011

Explanation: The resultant output of Ex-or operation is 0 if both the inputs are the same, otherwise 1. That's why the resultant output of given bits is 101011.

36) Boolean algebra deals with how many values.

1. It deals with only four discrete values.
2. It deals with only five discrete values.
3. It deals with only three discrete values.
4. It deals with only two discrete values.

Answer: d) It deals with only two discrete values.

Explanation: Boolean algebra deals with only two discrete values, 0 and 1. 0 means false, and 1 means true.

37) Which of the following Law of Boolean proofs the X.X=X?

1. Identity Law
2. Double Complement Law
3. Complement Law
4. Idempotent Law

Explanation: Idempotent Law proofs AND form and OR form. It proofs X+X=X and X.X=X.

38) According to the symmetric matrix, which of the following statement is correct?

1. A = AT
2. All the diagonal elements of a symmetric matrix are One.
3. A = -AT
4. All the diagonal elements of a symmetric matrix are Zero.

Explanation: Symmetric matrix is a square matrix. That's why its transpose is equal to the given symmetric matrix.

39) Which of the following matrix having only one row and multiple columns?

1. Diagonal Matrix
2. Row Matrix
3. Column Matrix
4. None of the mentioned

Explanation: A row matrix is a matrix that consists of one row and multiple columns. The order of the row matrix is 1 x N, where N is the number of columns of a row matrix.

Following are the various examples of row matrix:

1. [ 6 5 4 ]: The order of this matrix 1 x 3, i.e., 1 row and three columns.

2. [ 0 ]: The order of this matrix is 1 x 1, i.e., 1 row and 1 column.

3. [ 1 2 0 6 8 9 ]: The order of this matrix is 1 x 6, i.e., 1 row and 6 column.

40) Which of the following matrix having only one column and multiple rows?

1. Diagonal Matrix
2. Row Matrix
3. Column Matrix
4. None of the mentioned

Explanation: A column matrix is a matrix that consists of one column and multiple rows. The order of the row matrix is N x 1, where N is the number of rows of a column matrix.

41) Which of the following condition is correct if we want to add two matrices?

1. Both rows and columns of both the matrices which we want to add are the same
2. Columns of both the matrices which we want to add are equal
3. Rows of both the matrices which we want to add are the same
4. a number of the first matrix's rows should be equal to the number of the second matrix's column, which we want to add.

Answer: a) Both rows and columns of both the matrices which we want to add are the same.

Explanation: If we want to add the two matrices, then the order of their rows and columns are the same.

42) A+B = B+A is a true or false statement if the order of A matrix and B matrix is the same.

1. False
2. True

Explanation: A+B = B+A is a true statement because the addition of two matrices is commutative.

43) XY = YX is a true or false statement if the order of A matrix and B matrix is the same.

1. False
2. True

Explanation: XY = YX is a false statement because the multiplication of two matrices is not commutative.

44) Universal logic gate is__________.

1. OR
2. NOT
3. NAND
4. AND

Explanation: NAND is a logic gate that can easily implement or create all the other logic gates without the help of three basic logic gates.

45) In which year Maurice Karnaughin introduced the Karnaugh map?

1. 1953
2. 1956
3. 1952
4. 1950

Explanation: In the year 1953, Maurice Karnaughin invented the Karnaugh map.

46) Canonical forms for a boolean expression has _______ types.

1. Three types
2. Four types
3. Two types
4. Five types

Explanation: Canonical Form for a boolean expression has two types. The first form is a product of max-terms, and another form is the sum of min-terms.

47) The use of Boolean algebra is ____________.

1. in building the algebraic functions.
2. in building logic symbols.
3. in circuit theory.
4. in designing the digital computers.

Answer: d) in designing the digital computers.

Explanation: The widely use of Boolean algebra is in designing digital computers and various electronic circuits.

48) Boolean algebra deals with how many values.

1. It deals with only four discrete values.
2. It deals with only five discrete values.
3. It deals with only three discrete values.
4. It deals with only two discrete values.

Answer: d) It deals with only two discrete values.

Explanation: Boolean algebra deals with only two discrete values, 0 and 1. 0 means false, and one means true.

49) Which search compares each element with the searching element till not found?

1. Merge search
2. Sequential Search
3. Binary search
4. none of the mentioned

Explanation: Sequential or Linear searching algorithm compares each element of the given list one by one with the searching element till the searching element is not found.

50) If a user wants to sort the unsorted list of n elements, then the insertion sort starts with which element of the list.

1. First element of the list
2. the second element of the list
3. the Third element of the list
4. the Fourth element of the list

Answer: b) the second element of the list

Explanation: If a user wants to sort the unsorted list of n elements with the insertion sort. Then the sorting algorithm starts sorting with the second element of the list.

51) What is the complexity of the bubble sort algorithm?

1. O(n2)
2. O(n)
3. O(log n)
4. O(n log n)

Explanation: O(n2) is the complexity of the bubble sort algorithm, where n is the number of sorted elements of the list.

52) What is the worst case of a linear search algorithm?

1. When the searching item is present in the middle of the list.
2. When the searching item is the last element in the list.
3. When the searching is not available in the list.
4. When the searching item is the last element in the list or is not present in the list.

Answer: d) When the searching item is the last element in the list or is not present in the list.

Explanation: The worst case of the linear search algorithm is when the searching item is the last element in the list or is not present in the list.

53) Which algorithm uses the previous outputs for finding the new outputs?

1. Dynamic Programming algorithms
2. Divide and Conquer algorithm
3. Brute Force algorithm
4. None of them

Explanation: Dynamic programming algorithms are those algorithms that find the new outputs by using the previous outputs of the same problem.

54) Which option is correct for representing an algorithm?

1. Pseudo codes
2. Flow charts
3. Statements in the common language
4. All of them

Explanation: Pseudo codes, flow charts, and the statement in the common language are used for representing the algorithm.

55) Which case does not exist in complexity theory?

1. Average case
2. Null case
3. Best case
4. Worst Case

Explanation: Average, worst, and best case are the three cases that always exist in the complexity theory. There is no Null case in the theory of complexity.