You are on page 1of 203

GATE NoteBook

Target JRF - UGC NET Computer Science Paper 2

1000 MEQs
100 Qs on Discrete Structures
and Optimization
Most Expected Questions Course
GATE NoteBook
Target JRF - UGC NET Computer Science Paper 2

1000 MEQs
50 Qs on Discrete Structures and
Optimization
Most Expected Questions Course
601
601
602
603
603
604
605
605
606
607
608
608
609
609
610
610
611
611
612
613
613
614
615
615
616

A.

B.

C.

D.

E.
A.

B.

C.

D.

E.
A.
617
B.

C.

D.

E.
A.

B.

C.

D.

E.
A.

B.

C. 618
D.

E.
A.

B.

C.

D.

E.
A.
619
B.

C.

D.
A.

B.

C.

D.
A.
620
B.

C.

D.

E.
A.

B.

C.

D.

E.
A.
621
B.

C.

D.

E.
A.
621
B.

C.

D.

E.
622
A.

B.

C.

D.
622
A.

B.

C.

D.
623
A.

B.

C.

D.
623
A.

B.

C.

D.
A.
624
B.

C.

D.
A.
624
B.

C.

D.
A relation R on a set A is called reflexive if (a,a) € R holds for every element a € A .i.e. if set A = {a,b}

then R = {(a,a), (b,b)} is reflexive relation. The number of Reflexive Relations on a set with n
elements is?

(A) n! 625
(B)2𝑛(𝑛+1)/2
(C)2𝑛(𝑛−1)/2
(D)2𝑛(𝑛−1)
A relation R on a set A is called reflexive if (a,a) € R holds for every element a € A .i.e. if set A = {a,b} then R =
{(a,a), (b,b)} is reflexive relation. The number of Reflexive Relations on a set with n elements is?
(A) n!
(B) 2𝑛(𝑛+1)/2
(C) 2𝑛(𝑛−1)/2
(D)2𝑛(𝑛−1)
625
Ans: D
Sol:
A relation has ordered pairs (a,b). Now a can be chosen in n ways and same for b. So set of ordered pairs contains
n2 pairs. Now for a reflexive relation, (a,a) must be present in these ordered pairs. And there will be total n pairs
of (a,a), so number of ordered pairs will be n2-n pairs. So total number of reflexive relations is equal to 2 power
n2-n , which equals to 2n(n-1)
Consider a simple undirected graph G with 40 vertices then maximum number of edges in this
graph without self-loop and multiple edges between 2 vertices is?
(A) 40
(B) 80 626
(C) 780
(D) 820
Consider a simple undirected graph G with 40 vertices then maximum number of edges in this
graph without self-loop and multiple edges between 2 vertices is?
(A) 40
(B) 80 626
(C) 780
(D) 820

Ans: C
Solution:
Maximum edges in a simple graph with n vertices = n(n-1) / 2 = (40*39) / 2 = 780
The number of elements in the power set of A where
A= { {1,2},{1,2,1},{1,2,2,1} }

A. 8
B. 4
C. 2
627
D. 1
The number of elements in the power set of A where
A= { {1,2},{1,2,1},{1,2,2,1} }

A. 8
B. 4
C. 2
627
D. 1

Ans: C
Solution: (C)
A= { {1,2},{1,2,1},{1,2,2,1} }
As set do not contain duplicate elements So, A = { {1,2} } only then P(A) will contain 2^1 =2
elements
Consider the set of integers I . Let D denotes “division with an integer quotient” e.g (4D8). Then D is :
Select the correct options :

A. reflexive , not symmetric , transitive


B. not reflexive, not symmetric , transitive 628
C. reflexive,symmetric ,transitive
D. not reflexive, symmetric , not transitive
Consider the set of integers I . Let D denotes “division with an integer quotient” e.g (4D8). Then D is :
Select the correct options :

A. reflexive , not symmetric , transitive


B. not reflexive, not symmetric , transitive 628
C. reflexive,symmetric ,transitive
D. not reflexive, symmetric , not transitive

Ans: (B)

Solution:
(B)
(0D0) not possible so not reflexive.
(4D8) Yes but (8D4) not possible so not symmetric.
(2D4) AND (4D8) so (2D8) is transitive.
Consider a bipartite graph G. Which of the following statements is correct about G?
(A) It does not contain odd cycle
(B) It is 2-colorable
(C) The spectrum of G is symmetric
(D) All of the above
629
Consider a bipartite graph G. Which of the following statements is correct about G?
(A) It does not contain odd cycle
(B) It is 2-colorable
(C) The spectrum of G is symmetric
(D) All of the above
629
Ans: D
Sol:
All statements given in option A, B and C are correct about bipartite graph.
Which of the following is true regarding relations?
(A) Identity relation I on set A is reflexive, transitive but not symmetric
(B) Void Relation R = Φ is symmetric and transitive but not reflexive
(C) Universal relation is reflexive, symmetric but not transitive.
(D) All of the above
630
Which of the following is true regarding relations?
(A) Identity relation I on set A is reflexive, transitive but not symmetric
(B) Void Relation R = Φ is symmetric and transitive but not reflexive
(C) Universal relation is reflexive, symmetric but not transitive.
(D) All of the above
630

Ans: B
Solution:
The different relations correctly can be expressed as
Identity relation I on set A is reflexive, transitive and symmetric
Void Relation R = Φ is symmetric and transitive but not reflexive
Universal relation is reflexive, symmetric and transitive.
Find no. of ways in circular arrangement with 6 boys and 7 girls sit together
A. 6! * 5!
B. 6! * 7P6
C. 13!
D. 8!
631
Find no. of ways in circular arrangement with 6 boys and 7 girls sit together
A. 6! * 5!
B. 6! * 7P6
C. 13!
D. 8!
631

Answer is B,
For circular arrangement, no. of ways= (n-1)!
So total no. of ways possible = 7!/7 * 7P6
= 6! * 7P6
There are two relations R1 and R2 both are Antisymmetric and Transitive on a set S.
Which statement is true ?

A. R1 U R2 = not antisymmetric , R1 ∩ R2 = always transitive 632


B.R1 U R2 = not antisymmetric , R1 ∩ R2 = not transitive
C.R1 U R2 = always antisymmetric , R1 ∩ R2 = not transitive

D.R1 U R2 = not antisymmetric , R1 ∩ R2 = not transitive


There are two relations R1 and R2 both are Antisymmetric and Transitive on a set S.
Which statement is true ?

A. R1 U R2 = not antisymmetric , R1 ∩ R2 = always transitive 632


B.R1 U R2 = not antisymmetric , R1 ∩ R2 = not transitive
C.R1 U R2 = always antisymmetric , R1 ∩ R2 = not transitive

D.R1 U R2 = not antisymmetric , R1 ∩ R2 = not transitive

Ans : A

Solution : (A)

R1 U R2 = not antisymmetric , R1 ∩ R2 = always transitive


Choose the correct option based on 2 statements .
1) If a graph G is connected then , the complement of G (G’) is always disconnected.
2) Bipartite graph are always 2 colourable , can contain odd length cycle

633
A. 1 is false , 2 is false
B. 1 is true , 2 is false
C. 1 is false,2 is true
D. 1 is true , 2 is true
Choose the correct option based on 2 statements .
1) If a graph G is connected then , the complement of G (G’) is always disconnected.
2) Bipartite graph are always 2 colourable , can contain odd length cycle

633
A. 1 is false , 2 is false
B. 1 is true , 2 is false
C. 1 is false,2 is true
D. 1 is true , 2 is true

Ans : A

Solution : (A)

If G is connected then G’ may be connected or disconnected

Bipartite graph does not contain odd length cycle.


A cyclic group is always _________
a) abelian group
b) monoid
c) semigroup 634
d) subgroup
A cyclic group is always _________
a) abelian group
b) monoid
c) semigroup 634
d) subgroup

Answer: a
Explanation: A cyclic group is always an abelian group but every
abelian group is not a cyclic group. For instance, the rational
numbers under addition is an abelian group but is not a cyclic
one.
A cyclic group is a group that can be generated by a single
element. (the group generator). Cyclic groups are Abelian.
Find the number of ways in which 4 people E, F, G, H, A, C can be seated at a
round table, such that E and F must always sit together.
a) 32
b) 290
c) 124
d) 48 635
Find the number of ways in which 4 people E, F, G, H, A, C can be seated at a
round table, such that E and F must always sit together.
a) 32
b) 290
c) 124
d) 48 635

Answer: d
Explanation: E and F can sit together in all arrangements in 2! Ways. Now, the
arrangement of the 5 people in a circle can be done in (5 – 1)! or 24 ways.
Therefore, the total number of ways will be 24 x 2 = 48.
GATE NoteBook
Target JRF - UGC NET Computer Science Paper 2

1000 MEQs
50 Qs on Discrete Structures and
Optimization
Most Expected Questions Course
636
637
638
639
ANSWER (B)
Consider statements:
S1 : A finite lattice is always bounded.
S2 : Complemented lattice is a proper subset of bounded lattice.
S3 : A bounded and complemented lattice may or may not be a distributive lattice.

Which of the following is/are true? 640


A.) S1 and S2 only
B.)S2 and S3 only
C.)S1 and S3 only
D.)S1, S2 and S3
Consider statements:
S1 : A finite lattice is always bounded.
S2 : Complemented lattice is a proper subset of bounded lattice.
S3 : A bounded and complemented lattice may or may not be a distributive lattice.

Which of the following is/are true? 640


A.) S1 and S2 only
B.)S2 and S3 only
C.)S1 and S3 only
D.)S1, S2 and S3
641
642
643
YES

NO

YES
644
645
Which is Distributive Lattice ?

646
647
Here in the given lattice a should be related as

(a,a) , (a,b), (a,c), (a,d), (a,e) b: (b,c), (b,e), (b,b). c: (c,c), (c,e) d: (d,d), (d,e) e: (e,e)

all pairs are already present here . Thus answer will be zero.
648
B,h
649
a) All rabbits hop.
b) All animals are hopping rabbits.
c) There exists an animal that, if it is a rabbit, then it hops.
d) Some rabbits hop.
Let G be a complete undirected graph on 6 vertices. If vertices
of G are labeled, then the number of distinct cycles of length 4
in G is equal to
650
(A) 15
(B) 30
(C) 45
(D) 360
Let G be a complete undirected graph on 6 vertices. If vertices There can be total 6C4 ways to pick 4 vertices from 6.
The value of 6C4 is 15.
of G are labeled, then the number of distinct cycles of length 4 Note that the given graph is complete so any 4
in G is equal to vertices can form a cycle.
There can be 6 different cycle with 4 vertices. For
(A) 15 example, consider 4 vertices as a, b, c and d. The
(B) 30 three distinct cycles are
cycles should be like this
(C) 45 d c (a, b, c, d,a)
abcda
(D) 360 (a, b, d, c,a)
abdca (a, c, b, d,a)
(a, c, d, b,a)
adbca (a, d, b, c,a)
a b (a, d, c, b,a)

(a, b, c, d,a) and (a, d, c, b,a)


(a, b, d, c,a) and (a, c, d, b,a)
(a, c, b, d,a) and (a, d, b, c,a)
are same cycles.
So total number of distinct cycles is (15*3) = 45.
Consider the recurrence relation a1=4, an=5n+an-1. The value of
a64 is _________
651
a) 10399
b) 23760
c) 75100
d) 53700
Consider the recurrence relation a1=4, an=5n+an-1. The value of
a64 is _________
651
a) 10399
b) 23760
Answer: a
c) 75100
Explanation: an=5n+an-1
d) 53700
= 5n + 5(n-1) + … + an-2
= 5n + 5(n-1) + 5(n − 2) +…+ a1
= 5n + 5(n-1) + 5(n − 2) +…+ 4 [since, a1=4]
= 5n + 5(n-1) + 5(n − 2) +…+ 5.1 – 1
= 5(n + (n − 1)+…+2 + 1) – 1
= 5 * n(n+1)/ 2 – 1
an = 5 * n(n+1)/ 2 – 1
Now, n=64 so the answer is a64 = 10399.
Determine the value of a2 for the recurrence relation an = 17an-1 + 30n with a0=3.
a) 4387 652
b) 5484
c) 238
d) 1437
Determine the value of a2 for the recurrence relation an = 17an-1 + 30n with a0=3.
a) 4387
b) 5484
c) 238
d) 1437

Answer: d
Explanation: When n=1, a1=17a0+30, Now a2=17a1+30*2. By substitution, we get a2=17(17a0+30)+60. Then
regrouping the terms, we get a2=1437, where a0=3.
Determine the solution for the recurrence relation bn=8bn-1−12bn-2 with b0=3 and b1=4.
a) 7/2*2n−1/2*6n
b) 2/3*7n-5*4n
653
c) 4!*6n
d) 2/8n
Determine the solution for the recurrence relation bn=8bn-1−12bn-2 with b0=3 and b1=4.
a) 7/2*2n−1/2*6n
b) 2/3*7n-5*4n
c) 4!*6n
d) 2/8n

Answer: a
Explanation: Rewrite the recurrence relation bn-8bn-1+12bn-2=0.
Now from the characteristic equation: x2−8x+12=0 we have x: (x−2)(x−6)=0, so x=2 and x=6 are the characteristic
roots.
Therefore the solution to the recurrence relation will have the form: bn=b2n+c6n.
To find b and c, set n=0 and n=1 to get a system of two equations with two unknowns:
3=b20+c60=b+c, and 4=b21+c61=2b+6c.
Solving this system gives c=-1/2 and b=7/2.
So the solution to the recurrence relation is, bn=7/2*2n−1/2*6n.
Which of the following statement is correct?
a) p ∨ q ≡ q ∨ p
654
b) ¬(p ∧ q) ≡ ¬p ∨ ¬q
c) (p ∨ q) ∨ r ≡ p ∨ (q ∨ r)
d) All of mentioned
Which of the following statement is correct?
a) p ∨ q ≡ q ∨ p
654
b) ¬(p ∧ q) ≡ ¬p ∨ ¬q
c) (p ∨ q) ∨ r ≡ p ∨ (q ∨ r)
d) All of mentioned

Answer: d
Explanation: Verify using truth table, all are correct.
Find the value of a4 for the recurrence relation an=2an-1+3, with a0=6.
a) 320
655
b) 221
c) 141
d) 65
Find the value of a4 for the recurrence relation an=2an-1+3, with a0=6.
a) 320
b) 221
c) 141
d) 65

Answer: c
Explanation: When n=1, a1=2a0+3, Now a2=2a1+3. By substitution, we get a2=2(2a0+3)+3.
Regrouping the terms, we get a4=141, where a0=6.
What is the recurrence relation for 1, 7, 31, 127, 499?
a) bn+1=5bn-1+3
b) bn=4bn+7!
656
c) bn=4bn-1+3
d) bn=bn-1+1
What is the recurrence relation for 1, 7, 31, 127, 499?
a) bn+1=5bn-1+3
b) bn=4bn+7!
c) bn=4bn-1+3
d) bn=bn-1+1

Answer: c
Explanation: Look at the differences between terms: 1, 7, 31, 124,…. and these are growing by a factor of 4. So, 1⋅4=4,
7⋅4=28, 31⋅4=124, and so on. Note that we always end up with 3 less than the next term. So, bn=4bn-1+3 is the
recurrence relation and the initial condition is b0=1.
¬ (p ↔ q) is logically equivalent to ________
a) p ↔ ¬q
b) ¬p ↔ q
657
c) ¬p ↔ ¬q
d) ¬q ↔ ¬p
¬ (p ↔ q) is logically equivalent to ________
a) p ↔ ¬q
b) ¬p ↔ q
c) ¬p ↔ ¬q
d) ¬q ↔ ¬p
Let the set be A= {a, b, c, {a,b}} then which of the following is false?
a) {a, b} Є A 658
b) a Є A
c) {a} Є A
d) b, c ЄA
Let the set be A= {a, b, c, {a,b}} then which of the following is false?
a) {a, b} Є A 658
b) a Є A
c) {a} Є A
d) b, c ЄA

Answer: c
Explanation: Only elements belongs to a set, {a} is a subset of this set.
How many elements in the Power set of set A= {{Φ}, {Φ, {Φ}}}?
1.4 elements
659
2.2 elements
3.6 elements
4.5 elements
How many elements in the Power set of set A= {{Φ}, {Φ, {Φ}}}?
1.4 elements
2.2 elements
3.6 elements
4.5 elements

Answer: a) 4 elements
Explanation: Set A contains two elements. So, the number of elements in the power set of Set A is 4.
Power set of empty or Null set has exactly _________ subset.
1.One
2.Two
3.Zero
660
4.Three
Power set of empty or Null set has exactly _________ subset.
1.One
2.Two
3.Zero
4.Three

A
¬ (A ∨ q) ∧ (A ∧ q) is a ___________
a) Tautology 661
b) Contradiction
c) Contingency
d) None of the mentioned
¬ (A ∨ q) ∧ (A ∧ q) is a ___________
a) Tautology
b) Contradiction
c) Contingency
d) None of the mentioned

Answer: b
Explanation: ≡ (¬A ∧ ¬q) ∧ (A ∧ q)
≡ (¬A ∧ A) ∧ (¬q ∧ q)
≡ F ∧ F ≡ F.
What is the dual of (A ∧ B) v (C ∧ D)?
a) (A V B) v (C v D)
662
b) (A V B) ^ (C v D)
c) (A V B) v (C ∧ D)
d) (A ∧ B) v (C v D)
What is the dual of (A ∧ B) v (C ∧ D)?
a) (A V B) v (C v D)
b) (A V B) ^ (C v D)
c) (A V B) v (C ∧ D)
d) (A ∧ B) v (C v D)

Answer: b
Explanation: In dual ∧ is replaced by v and vice – versa.
Which of the following satisfies commutative law?
663
a) ∧
b) v
c) ↔
d) All of the mentioned
Which of the following satisfies commutative law?
a) ∧
b) v
c) ↔
d) All of the mentioned

Answer: d
Explanation: All of them satisfies commutative law.
If the truth value of A v B is true, then truth value of ~A ∧ B can be ___________
a) True if A is false
664
b) False if A is false
c) False if B is true and A is false
d) None of the mentioned
If the truth value of A v B is true, then truth value of ~A ∧ B can be ___________
a) True if A is false
b) False if A is false
c) False if B is true and A is false
d) None of the mentioned

Answer: a
Explanation: If A is false then both the condition are obeyed.
665

Which of the above two are equivalent?


(A) I and III
(B) I and IV
(C) II and III
(D) II and IV
Which of the above two are equivalent?
(A) I and III
(B) I and IV
(C) II and III
(D) II and IV
Given that
B() means “is a bear”
F() means “is a fish” and 666
E(a,b) means “ eats b”
Then what is the best meaning of

∀x[F(x)→∀y(E(y,x)→b(y))]

a.Every fish is eaten by some bear


b.Bears eat only fish
c.Every bear eats fish
d.Only bears eat fish
Given that
B() means “is a bear”
F() means “is a fish” and
E(a,b) means “ eats b”
Then what is the best meaning of

∀x[F(x)→∀y(E(y,x)→b(y))]

a.Every fish is eaten by some bear


b.Bears eat only fish
c.Every bear eats fish Let us translate the given statement :
d.Only bears eat fish
For every x,if x is a fish, then for every y, if y
eats x then y is bear..

This is enforcing the condition that every


animal that eats a fish is a bear.. So only
option d matches..
667
P only if Q

P : I stay
Q : You go

PQ
converse : Q  P

1 If you go then I stay

I stay if you go
668
c
669
a
670
P only if Q

P –> Q

~(~P v Q)

P ^ ~Q

a Match will be played


but it is humid day
671
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
700

Copy protected with Online-PDF-No-Copy.com

You might also like