DRDO(CEPTAM) Whole Test paper | 18927

__DRDO (CEPTAM) whole Test Paper -100 Questions__

1. Which of the following regular expressions describes the language- the set of all strings over {0, 1}containing at least two 1’s?

A. (0+1)*11(0+1)* B. 0*110*

C. 0*10*10*

D. (0+1)*1(0+1)*1(0+1)*

2. Which of the following is / are regular language(s) ?

I. { ambn | m , n ≥0}

II. {w ? {a, b}*| has equal number of a’ s and b’ s}

III. {ambn | m>n}

IV. {w ? {a , b}* w has even number of a’ s}

A. Only

B. And only

C. And only

D. Only

3. Which of the following is true?

A. For every NFA there is an equivalent PDA.

B. Nondeterministic TMs are more powerful than deterministic TMs. C. DPDAs and NPDAs are equivalent in power.

D. NFAs accept the class of CFLs.

15. A variable X has been assigned fresh values in statements numbered 6, 9 and

12 in a 25- statement program which does not have any jump instructions.

This variable is used in statements numbered 7, 8, 10, 16 and 17.the statement range where the register, used by the variable X, could be assigned to some other variable are-

A. 8-9, 10- 12, 17- 25

B. 11, 18-25

C. 17-25

D. Non of the above

4. Let L be a CFL. Then L’ must be

A. CFL but not regular.

B. Recursive.

C. Recursively Enumerable but not Recursive.

D. Regular but not CFL.

5. Which of the following is FALSE?

A. CFLs are closed under union but not closed under complement.

B. Regular sets are closed under intersection and Kleene Closure.

C. Recursive languages are closed under intersection but not closed under complement.

D. Recursively enumerable languages are closed under union and intersection.

6. Which of the following is NOT POSSIBLE?

A. Finding out a minimal DFA for any arbitrary regular language.

B. Constructing a deterministic TM for any arbitrary CFL.

C. Determining whether two CFGs generate the same language.

D. Given an arbitrary TM M (which halts on all inputs) whether the complement of the language accepted by M is recursive.

7. Which of the following is FALSE?

A. Regular expressions and DFAs are equivalent.

B. A DPDA cannot accept by any arbitrary CFL.

C. The language accept by any TMs is a CFL.

D. Complement of every regular language is CFL.

8. Consider the languages L1 and L2 given below.

L1= {<M1, M2>| M1 and M2 are NFAs and L (M1 )= L (M2)}L2= {<M1, M2>| M1 and M2 are TMs and L (M1 )= L (M2)}Which of the following is true?

A. L1 is undecidable but L2 is decidable.

B. L2 is undecidable but L1 is decidable.

C. Both L1 and L2 are undecidable.

D. Both L1 and L2 are decidable.

9. Let A and B be languages corresponding to two decision problems πA and πB respectively. Let A be NP – complete problem, then hat would not B NP.

Which of the following is true?

A. B is NP- complete

B. A proportional p B

C. B proportional p A

D. None of the above.

10. if there is a polynomial time algorithm for an NP- complete problem, then that would not imply which of t he following:

A. P = NP

B. NP = Co- NP

C. P = NP ∩ Co-NP

D. P NP

11. A 1KB RAM can be organized as an 8 K bit RAM.

A. Using a 1 to 8 line demultiplexer.

B. Using an 8 to 1 multiplexer.

C. Using an 8 – input OR gate.

D. None of the above.

12. A 2 KB RAM can be economically organized using-

A. 64 numbers of 256 bit RAM chip and a 1/8 line decoder.

B. 64 numbers of 256 bit RAM chip and a 1/64 line decoder.

C. 8 numbers of 256 bit RAM chips and a 1/8 line decoder.

D. 8 numbers of 256 bit RAM chips and a 1/64 line decoder

13. With reference to RETURN instruction, which of the following statement is / are true?

1. The instruction can be used only to take the flow of control back to the program from which it initially jumped.

2.The instruction retrieves the address using the current stack pointer from the stack and alters the control to the program pointed to by it.

3. The instruction works only if the registers used in the main program have been pushed and later popped before its execution.

4.The instruction can be used only in conjunction with the call instruction.

A. 1st and 2nd

B. 2nd only

C. 1st, 2nd and 3rd only

D. All the statement are true

14. In an n- CPU shared bus system, if is the probability that any CPU requests the bus in a given cycle, the probability that only one CPU uses the bus is given by-

A. Nz(1-z)(n-1)

B. Z(1-z)(n-1)

C. N(1-z)n

D. (N-1)z(1-z)

15. A variable X has been assigned fresh values in statements numbered 6, 9 and 12 in a 25- statement program which does not have any jump instructions.

This variable is used in statements numbered 7, 8, 10, 16 and 17.the statement range where the register, used by the variable X, could be assigned to some other variable are-

A. 8-9, 10- 12, 17- 25

B. 11, 18-25

C. 17-25

D. Non of the above

16. If the Intel Pentium processors, was not made compatible to programs written for its predecessor, it could have been designed to be a faster processor.

A. The statement is true

B. The statement is false

C. The speed cannot be predicted.

D. Speed has nothing to do with the compatibility.

17. A certain snooping cache an snoop only an address lines. Which of the following is true?

A. This would adversely affect the system if the write through protocol is used.

B. This would run well if the write through protocol is used.

C. Data snooping is mandatory.

D. None of the above.

18. Repeated occurrence of identical interrupt during execution of this service routine can result in-

A. Program error.

B. Stack overflow.

C. Hardware error.

D. None of the above.

19. Micro programmed control is not fit for RISC architectures because-

A. It tends to slow down the processor.

B. It consumes more chips area.

C. Handling a large number of registers is impossible in micro programmed systems.

D. The 1 instruction / cycle timing requirement for RISC is difficult to achieve for all instructions.

20. A certain RISC processor has 12register windows and 16 global registers. Each window has 8 input, 16 local and 8 output registers. The total number of registers in the processor is –

A.312

B.320

C.296

D.304

21. In a certain system the main memory access time is 1000 ns. The cache memory is 10 times faster then the main memory uses the write through protocol. If the hit ratio for read request is 0.92 and 85% of the memory requests generated by the CPU are for the read, the remaining being for write, then the average time considering both read and write request is –

A. 14.62 ns

B. 348.47 ns

C. 29.62 ns

D. 296.2 ns

22. Shown below are segments of a code run on a CISC and a RISC architecture separately.

CISC RISC MOV AX, 05 MOV AX, 00

MOV BX, 06 MOV BX, 05

MUL AX, BX; Multiply AX with BX MOV CX, 06

START: ADD AX, BX

LOOP START ; loop till

CX=0

If the MUL instruction takes 402 clock cycles, which of the following statement is true?

A. The CISC code will faster by a factor of 1.8.

B. The RISC code will run aster by a factor of 2.8.

C. The CISC code will faster by a factor of 0.025.

D. The RISC code will run aster by a factor of 40.

23. The frequent of different types of instructions executed by a machine is tabulated below.

Operand Accessing Mode Frequency in %

register 30

Immediate 20

Direct 22

Memory indirect 17

Index 11

Assuming two cycles are consumed for an operand to be read from the memory,

one cycle for index arithmetic computations and zero cycles if operands are available in registers or with in instruction itself, the average operand fetch rate of the machine is-

A.1.45

B.2.45

C.2.67

D.2.34

24. A 1 ns cycles time unpipeline processor consumes 4 cycles for ALU operations,3 cycles for branches and 5 for memory operations. The relative frequencies of these operations are 45%, 15% and 40% respectively. What is the speedup in the instruction execution rate if the same were pipelined? Assume a 0.4 ns overhead consumed in setup and clock skew taken together.

A.4.25

B.3.04

C.3.85

D.3.44

25. the range of intigers that one can represent using an n –bit 2s complement number system is –

A. -2(n-1) to (2n-1)

B. -2(n-1) to (2(n-1)-1)

C. -2n to(2n-1)

D. -2n +1 to (2(n-1) -1)

26. the octal representation of the number (1FO)16 is-

A(760)8

B.(13300)8

C.(170)8

D.(180)8

27

The minimized function f obtained from the K-map given above is –

a) C’E’+A’BCE+BCD’E

b) B’C’E’+A’BCE+ABCD’E+BC’E’

c) C’E’+A’BCE+BCDE

d) B’C’E+A’BCE+ABCD’E+BC’E

28. The standard sum of products of the function f = A+B’c is expressed as-

A. ∑m(1, 4, 5, 6, 7) + d(0, 2, 3)

B. ∑m(1, 4, 5, 6, 7)

C. ∑m(0, 2, 3) + d(1, 4, 5, 6, 7)

D. ∏M (1, 4, 5, 6, 7)

29. hazards in combinational circuits are removed by-

A. Enclosing the minterms that cause the hazard with a product term that overlaps both groupings.

B. Using NOT gates at all inputs.

C. Using NOT gates at all outputs.

D. None of the above.

30. four D – type flip flops are connected in such a manner that output Qi of one is connected to the D input of the next flip flop.the input to the initial D-flip flop is given by

D1 =Q3 XOR Q 4 Allflip flops are clocked synchronously. Which of the following statements is /are true?

i.D1 is ahead of Qi by one clock pulse.

ii.The circuit outputs the sequence 100010011010111 along all Qi ‘s

A. Only (i) is true

B. Only (ii) is true

C. Both (i) and (ii) are true

D. None of the statement is true.

31. Three is NOT gates are cascaded and the out put of the third provides input to the first. Which of the following statements is true?

A. The connection from the output to the will lead to contention and hence damage the circuit on power on.

B. The output is unpredictable making the circuit useless.

C. The output will be uniformly held at either logic 0 and logic 1.

D. The out put will alternate between logic 0 and logic 1 continuously.

32. A certain device dumps data into its interface register every 200 ns. The main memory access time is 50 ns. If the CPU were interfaced to his device in cycle stealing mode, what percentage of time does the CPU be in hold state?

A. 20

B. 25

C. 50

D. None of these

33. If a disc has a rotation speed of R rpm and track storage capacity of C bits, the data transfer rate of the drive is defined as-

A. R/C bits/min

B. C/R bits/min

C. 0.5(R*C) bits/min

D. R*C bits/min

34. In the NONIX operating system, the time required for various file read operations are given below:

Disk seek time: 25 msec

Disk latency time: 8 msec

Disk transfer time: 1 msec/Kbyte

Operating system overheads: 1 mse/Kbyte + 10 msec.

What is the time required to retrieve a block of Kbytes?

A. 45 msec

B. 47 msec

C. 90 msec

D. 94 msec

35. Which of t he following page replacement method guarantee the minimum number of page faults?

A. Replace the page whose next reference will be the farthest in future.

B. Replace the page whose next reference will be the nearest in future.

C. Replace the page whose most recent reference was the nearest in past.

D. Replace the page whose most recent reference was the farthest in past

36. Which of the following statement is/are true about paging?

P: it divides memory into units of equal size.

Q: it permits implementation of virtual memory. R: it suffers from internal fragmentation.

A. P only

B. Q only

C. R only

D. P and Q only

37. The sequence of page addresses generated by program is 1, 2, 2, 1, 3, 4, 2, 1, 3, 4.

This program is run on a system with main memory size equal to 3 pages. Which pages are in the memory just before 5th page fault, if least recently used page replacement is followed?

A.1, 2, 3

B.1, 2, 4

C.1, 3, 4

D.2, 3, 4

38. Assume that the following jobs are to be executed on a single processor system.

Job id CPU burst time

1 3

2 4

3 5

4 1

Assume that the jobs are arrived at time 0* and in the 1, 2, 3, 4. for round robin scheduling with time slice 1, what is the completion time for the jobs 2?

A. 7

B. 8

C. 9

D. 11

39. Consider the following jobs given below:

Job id arrival time CPU time

1 0 4

2 3 7

3 7 4

4 1 1

What is the average turnaround time with non- preemptive shortest job first scheduling algorithm?

A. 2.75

B. 5.75

C. 6.5

D. 8.5

40. which of the following statement is /are TRUE about thrashing?

P: implies excessive page faults. Q: CPU utilization decreases

R: implies less page faults. A. P only

B. Q only

C. P and Q only

D. Q and R only

41. A computer system has 9 printers, with a processes competing for them. Each process needs 3 printers. What is the maximum value of n for the system to be deadlock free?

A.3

B.4

C.5

D.6

42. A counting semaphore was initialized to eight. Then four P (wait) operations and six V (signal) operations are performed on the semaphore. What is the resulting value of the semaphore?

A.0

B.8

C.10

D.12

43. A computer system uses the Banker’s algorithm to deal with deadlocks its current state is shown in the table below, where P0, P1, P2 and P4 are processes and A, B, and C are resources types.

Maximum

A B C

P0 6 5 4

P1 3 4 2

P2 1 0 4

P3 3 2 5

Allocated

A B C

P0 0 3 4

P1 2 1 2

P2 0 0 2

P3 1 2 1

Available

A B C

4 3 1

Which of t he following is/are safe sequences?

P: P1, P0, P2, P3

Q: P1, P2, P0, P3

R: P1, P3, P0, P4

A. P and Q only

B. P and R only

C. Q and R only

D. All P, Q and R.

44. Which of the following most appropriately describes the language generated by the grammer: S ??aSa| bSb | ε

A. The set of string over {a, b}that begin and end with the same symbol. B. The set of palindromes over {a, b}.

C. The set of string over {a, b}with equal number of a’s and b’s.

D. The set of even length palindromes over {a, b}.

45. Consider the rule of the C programming language –“every variable must be declared before its use.” in which of the following phase of the compiler will an error violating this rule be detected?

A. Code generation B. Lexical analysis C. Syntax analysis

D. Semantic analysis.

46. Find the best match between the element of Group-1 and Group -2 given below.

Group-1 Group -2

P. Dataflow analysis 1. Lexical analysis

Q: Regular expression 2. Semantic analysis

R: Type Checking 3.Parsing

S: Pushdown Automata 4. Code optimization

A. P-4, Q-1, R-3, S-2

B. P-2, Q-1, R-4, S-3

C. P-1, Q-4, R-2, S-3

D. P-4, Q-1, R-2, S-3

47. Consider the grammar: S ??L= R | R L ?* R | id R ??L

Which of the following set of LR (0) items definitely does not represent a valid state of an LR (0) parser?

A. S ??L =?R, R ???L B. L ??id.

C. S ??L? = R, R ??L?

D. R ??L?

48. Which of the following is/are true?

i.A left – recursive grammar cannot be LL( 1 ).

ii.A right – recursive gammar cannot be LR(1).

iii.Every grammar that can be parsed by a canonical LR parser can also be parser by some SLR parser.

A. I and II only

B. I only

C. II only

D. I,II and III

49. Consider a state of an LR ( 0) parser containing the following two items only.

A → abB?

C → a?b

Which of the following CAN NOT be deducted from the information provided above?

A. There is shift – reference conflict in the parsing table. B. The given grammar is not LR(0).

C. There is reduce – reference conflict in the parsing table.

D. The goto function for this state on symbol b must lead to some state.

50. Who developed the original version of SQL?

A. Oracle

B. IBM

C. mySQL AB D. Microsoft

51 For the relational schema RK1K2 are the only candidate keys. R has a functional dependency X ??A

where X is a set of attributes and A is an attribute. It is known that A??K1 and A??K2 and X is not a superkey. Which of the following is true?

A. R should be in BCNF.

B. R is not surely in BCNF, but could be in 3NF

C. R is not surely in 3NF, but could be in 2NF

D. R is not surely in 2NF, but could be in 1NF

52. R is a rational schema with the following functional dependencies.

A ??DC B ??A C ??E E?BD

Which of the following is not a candidate key of R.

A. AD B. BE C. CD D. AB

53. If the following elements are inserted in the given order into initially empty B+tree in which each node can hold at most 4 pointers,

what will be the number of leaf nodes in the B+ tree at the end of the insertions?

1 3 5 6 7 8 14 22 32 33 37

A.4

B.5

C.6

D.7

54. In the following, T1 and T2 are transactions and A is an object. Which of the following has the potential of making T2 irrecoverable?

A. T2 writes A after T1 wrote A; T1 is uncommitted

B. T2 reads A after T1 wrote A ; T1 is uncommitted

C. T2 writes A after T1 wrote A ; T1 is committed

D. T2 reads A after T1 wrote A; T1 is uncommitted

55. Which of the following is impossibility?

A. A sparse primary index

B. A sparse secondary index

C. A dense primary index

D. A dense secondary index

56. RDBMS QUERY

57.RDBMS Query

58.DBMS Query

59. Arrange the following functions in increasing asymptotic order

(P)√ (log2n) (Q)√ n (R) 2 (log2n / log2 log2n) /*power of 2(then log part) */ (S) log2 log2(n!)

A)PQSR

B)PQRS

C)PSRQ

D)SPQR

60.Which of the following is false?

A) the aveg case time complexities of quick sort and heap sort are O(nlogn).

B) the worst case time complexities of quick sort and heap sort are O(n2).

C) the aveg case time complexities of merge sort and insertion sort are O(n2).

D) the worst case time complexities of quick sort and merge sort are O(nlogn).

61.Which of the following exemplifies Divide and conquer?

A)Heapsort

B)Insertion sort

C)Bubble sort

D)Merge sort.

62.Consider a sequence A of length n which is sorted except for one item that appears out of order.Which of the following can sort the sequence in O(n) time?

A)Heapsort

B)Quick sort

C)Merge sort

D)Insertion sort.

63.If T(n)= 3T(n/2)+n, if n>1. T(1)=1. Then T(n)=? A)Θ(n)

B) Θ(n (log23) ){n to the power log23}

C)Θ(n 3/2)

D) Θ(n (log23) log2n

64.Let S1= ∑nr/2r (r=0 to logn-1) .S2= ∑r2r (r=0 to logn-1) Which of the following is true?

A)S1= Θ(nlogn),S2= Θ(nlogn)

B) S1= Θ(n),S2= Θ(nlogn)

C) S1= Θ(nlogn),S2= Θ(n)

D) S1= Θ(n),S2= Θ(n)

65.Question based on Dynamic programming with memorization. Complexity is asked for a function.

66. To remove recursion from a program we have to use the following data structure:

A. array

B stack

C queue

D list

67. Absence of terminating condition in a recursive program causes the following run time error:

A) array out of bounds

b) stack overflow

c) null ptr access

d) division by zero

68.On a set of n elements linear search is preferred over binary search when there are :

a)Ω(log n) queries

b) O(log2 n) queries

c) o(log n) queries

d) Θ(log2 n) queries

69.#include <stdio.h> Void main() {

Int a=4,b=5,c=6; C+=a++ + ++b; Printf(“a=%d,b=%d,c=%d, \n”,a,b,c);

}

What is the o/p of the above c program:

a) 5 6 17

b) 56 18

c) 5 5 16

d) 5 6 16

70.what is the max size of the operator stack during the conversion of the infix exp A+B*C-D/E to postfix?

A)1

B)2

c)3

D)4

71. what is the max size of the operand stack while evaluating the postfix exp 6 2 3 + - 3 8 2 / + * ?

A)1

B)2

c)3

D)4

72. Binary search can be carried out on the set of ordered out on a set of ordered data items stored in a:

A. array

B stack

C queue

D list

73. To o/p a binary tree level by level we have to use the following data structure

A. array

B stack

C queue

D list

74. Which one of the following arrays satisfies max-heap property?

A) 16,10,12,8,3,5

B)16,8,5,10,12,3

c)16,12,8,3,5,10

D)10,16,12,8,5,3

75.The max number of comparisons required to sort 5 elements is

a) 4

B) 5

c) 6

d)7

76 The worst case time complexity of quicksort for n elements when the median is selected as the pivot element is :

a)Θ (n2)

b) O(n2)

c)Θ (n log n)

d) o( n log n)

77.The number of null links in a binary tree with n nodes is :

a) n-1 b) n

c) n+1 d) 2n

78.What is the max possible height of an AVL tree with 20 nodes ?

a)4

B) 5

c) 6

d)7

79.let T be a B-tree of order m and height h. If n is the no of key elements in T then the max value of n is :

a)(m-1) h-1

b)(m-1) h-1+1

C) m h-1

D) m h-1+1

80. Adjacency list is preferred over adjacency matrix when the graph is :

a)Planar

B) Dense

c) Clique

D) None of the above

81.A binary tree can be uniquely reconstructed from the following traversal(s):

A) preorder

B) postorder

c) preorder and postorder

d) inorder and preorder

82. In a simple connected undirected graph with n nodes (n>=2) the max number of nodes with distinct degrees is

a) n-1

b)n-2

c) n-3

d)2

83. The max number of edge disjoint cut sets in a simple graph with n nodes is:

a) n

b)2 n

84.If an undirected graph has Hamiltonian cycle then it is definitely :

a) tree

b) clique

c) Bi-connected

d) Tri-connected

85.If an undirected graph doesn’t have an odd cycle , then it is:

A)tree

b)planer

c)Bi-partite

d) clique

86. To color a cycle of length 9, max number of colors required is :

a)2 b)3 c)4 d)5

87.what is the number of edge disjoint Hamiltonian cycles in a complete graph G=(V,E),where |v|=n and n is odd?

a)n

b)? n/2 ?

c(n-1)/2

d) n 2

88. Given a set of n elements not all distinct, the majority element is one with freq>=n/2. So the majority elements is always the

A) max element

B) minimum element

C) mean element

D) median element

89.Let 01111 be the frame delimiter flag in a data link protocol. What is the transmitted bit sequence for the data 0111110111011110 using the bit stuffing method?

a)0111110111011110

b)011101101110111010

c)01111011011100111010

d)011100110111001110010

90. A frame 110010111001 is to be transmitted using the CRC with generating poly x3+x+1 to protect it from errors. What is the transmitted frame?

a)1101011001010

b)1111010110010

c)1110110110101

d)1110111010111

91.The distance between two microwave towers, with link capacity 100Mbps, is 24km and the speed of the signal is 3X108 m/s.

If the frame size is 16kb in the stop and wait protocol, what is the approx link utilization ? assume that the ack packets are negligible in size and there are no errors during comm..

A)33%

B)50%

C)66%

D) 75%

92.Two ground stations r connected by a 10Mbps Sat link. The altitude of the satellite is 36000km and the speed of the signal is 3X108 m/s.

What shd be the packet size for the channel utilization of 50% using go-back-100 sliding window protocol? assume that the ack packets are negligible in size and there are no errors during comm..

a) 1.5Kbytes

b)3 Kbytes

c)4.5 Kbytes

d)6 Kbytes

93.Match the following

I data link layer

P. POP3

II network layer

Q. UDP III Transport layer

R. RARP IV App layer

S. PPP

A) I-P, II-Q, III-R ,IV-S

B) I-P, II-R, III-Q ,IV-S

C) I-S, II-Q, III-R ,IV-P

D) I-S, II-R, III-Q ,IV-S

94.The sound trip propagation delay for 100Mbps Ethernet having 48-bit jamming signal is 64 μs .What is the minimum frame size?

A) 400 bytes

B)600 bytes

C)800 bytes

D) 1400 bytes

95. Match the following

I 802.3 P. wireless LAN

II 802.11 Q. Bluetooth

III 802.15 R. Ethernet

IV 802.16 S. wireless MAN

a) I-R, II-P, III-Q ,IV-S

b) I-R, II-P, III-S ,IV-Q

c) I-R, II-Q, III-P ,IV-S

d) I-P, II-R, III-S ,IV-Q

96.Match the following

I GATEWAY P. PHYSICAL LAYER

II SWITCH Q. DATA LINK LAYER

III ROUTER R. NETWORK LAYER

IV HUB S. TRANSPORT LAYER

a) I-S, II-P, III-R ,IV-Q

b) I-S, II-R, III-Q ,IV-P

c) I-R, II-Q, III-S ,IV-P

d) I-S, II-Q, III-R ,IV-P

97. which of the following statements is/r true about datagram subnet? P: each packet contains the full source and destination addresses.

Q: Two packets b/n source and destination can follow diff. paths.

a) P only

b) Q only

c) Both P and Q

d) Neither P nor Q.

98.A computer on a 6Mbps network is regulated by a token bucket.The token bucket is filled at a rate of 2Mbps.It is initially filled to a full capacity of 8Mb.How long can the computer transmit at the full 6Mbps?

a)1.3sec

b)1.6 sec

c)1.9 sec

d)2sec

99.The routing table of a router is shown below

Destination Subnet mask interface

132.81.0.0 255.255.0.0 Eth0

132.81.64.0 255.255.224.0 Eth1

132.81.68.0 255.255.255.0 Eth2

132.81.68.64 255.255.255.224 Eth3

A packet bearing a destination address 132.81.68.132 arrives at router. On which interface will it be forwarded?

a)Eth0

b)Eth1

c)Eth2

d)Eth3

100.which of the following statements is /are True about IP address?

P: IP address 128.128.255.255 is used for broadcasting on class B network.

Q: IP address 127.127.255.255 is used for loopback testing.

A)P only

B)Q only

C)Both P and Q

D)Neither P nor Q.