PhD - Computer Science - 2010

Embed Size (px)

Citation preview

  • 8/13/2019 PhD - Computer Science - 2010

    1/17

  • 8/13/2019 PhD - Computer Science - 2010

    2/17

  • 8/13/2019 PhD - Computer Science - 2010

    3/17

    U-5L1. The average case time complexity of finding minimum elementin a Max-heap having N elements isA. o(ri)B. o(/oeN)c. o(L)D. O(NloeI/)2. The integ:rs {1-1000} are stored in a Binary search rree (BST).suppose the search algorithm is implemented on the key 363, oneof the following sequences is lrloT a possible sequence of noclesthat is examined. It isA. 2, 252,401, 3gg, 330, 344, 397, 363B. 924, 220, glr,, 244,999, 25g, 362, 363c. 925,202, g1l,240, gL2, 345,245, 363D. 2, 399,397,2r9,266,3g2,3g1, 27g, 3633. It is NoT KNowN if an NP-complete problem A is such thatA. Ae NPB. Ae PC. A e NP-HardD. Circuit-Sat reducible to A.4. Which of the following statements is TRUE about the worst-cl,setime compleritE for operations on heaps?

    A. Neither insertion nor removal is better than linear.B. Insertion is better than linear, but removal is not.C. Removal is better than linear, but insertion is not.D. Both insertion and removal are better than linear.

  • 8/13/2019 PhD - Computer Science - 2010

    4/17

    u-565. A priority queue is implemented by storing the items in a min-heup (using an array for the heap items). In a min-heap, the

    va-lue at parent is less than the value at the child position' Ifre-heapification is done upward and the out-of-place node is atd,atali with priority given by datali,l, Which of the followingboolean expressions is TRUE to indicate that the re-heapificationIS NOT YET DONE.A. (r>0)B. (d,atal(i, - L) 12) < datalil)C. (, > 0) &8. (d,atal(i' - L) l2l < d'atali'\) ID. (i > 0) ll (d'atal(t' * L) 12) < datafi))

    6. An algorithm has a run time complexity of o(lo9 .nf). The al-gorithm requires 110 operations for an input of size 1000. whenthe input size is doubled to 2000, the algorithm now requires 120operations. What is your best gUess for the number of operationsrequired when the size is doubled to 4000?A. i30B. 140c. 150D. 160

    7. A stack data structure is used in which of the following imple-mentationsA, PrioritY queueB. DePth First SearchC. Breadth First SearchD. Post order braversal

    B. class of languages recognized by finite automata is calied as:A. Context Sensitive languages+

  • 8/13/2019 PhD - Computer Science - 2010

    5/17

    U .FbB. Recursive LanguagesC. Regular languagesD. Context free Languages

    9. Given an arbitrary Non-deterministic Finite Automaton (NFA)with N states, the maximum number of states in an equivalentminimized deterministic Finite Automaton (DFA) is at least.A. 172B. 2Nc. 2t{D. ,\,10. Which of the foilowing statements is FALSE?A. If a language is context free it can always be accepted by anon-deterministic push-down automatonB. The union of two context free languages is context freeC. The intersection of two context free languages is context freeD. A regular language is context free11. If the regular set A is represented by A : (01 + 1)* and theregular set B is represented by B - ((01).1-)., which of thefollowing statements is TRUE?A. A is a proper subset of BB. B is a proper subset of AC. A and B are incomparableD. A: B.12. TheLanguage L:{o'u:k} 0} isA. Regular LanguageB. Non-regular Language

  • 8/13/2019 PhD - Computer Science - 2010

    6/17

    u- 56

    C. Non Context-free languageD. None of the above13. The number of columns in a table is kriown as itsA. RangeB. CardinalityC. DomainD. Degree14. Tb transmit data bits 1011, the correct even parity seven bitHamming Code is:A. 0101101B. i010101c. 1100111D. 011011115. Which of the following is the name of the data structure in a com-

    piler that is responsible for managing information about variablesand their attributes?A. Parse TableB. Attribute GrammarC. Symbol TableD. Semantic Stack16. Overloading involves writing two or more functions with

    A. the same name and the same argument list- B. different names but the same argument iistC. the same name but different argument listD. different names and different argument list17. Cyclomatic complexity is a metric to count

  • 8/13/2019 PhD - Computer Science - 2010

    7/17

    u- 56

    18.

    A. the number of functionalities of a programB. the number of distinct paths a program hasC. the number of insertion points a program hasD. the average number of functions a class hasChidambaram A'[etri,c is used to measure efficiency ofA. fuuci,iun inleraclions in a citr,ssB. object oriented programsC. object oriented testingsD. object oriented designsResolution of externally defined symbols is performed b-vA. LinkerB. CompilerC. AssemblerD. Loaderwhich of the following is(are) serious problem(s) of file manage-ment systems?A. Data redundancyB. Program dependenceC. Lack of data independenceD. All of the aboveA database with network schema allowsA. one-tomany relationshipsB. many-to-many relationshipsC. data organization in tablesD. hierarchical data organization

    19.

    20.

    21.

  • 8/13/2019 PhD - Computer Science - 2010

    8/17

    u- 5622. How many bit strings of length 8 either start with a bit 1 or endwith the two bits 00?A. 160B. 255c. 128D. 6423. Which of the following algorithms can be used to find a spanningtree of a given connected $aph G?A. Breadth First SearchB. Depth First SearchC. Kruskal's AlgorithmD. All of the above24. In standard computer networking terminology we use the terms(i) segment and (ii) frame, both to describe packets. Usually

    these terms refer to which of the following:Segment deals with layer 3 packets (network) while frame isfor lay'er 4 (transport) packets.Segment deals with layer 3 packets (network) while flame isfor layer 2 (data link) packets.Both actually deal with layer 2 (data link) packets but justare different namesD. Segment deals with layer 4 (transport) while frame is forlayer 2 (data link) packets.25. The least number of IP addresses a router and a host may have,excluding loopback addresses, is

    A. As many for a router and one for a hostB. Two for a router and one for a host

    A.B.C.

  • 8/13/2019 PhD - Computer Science - 2010

    9/17

    u-56Both routers and hosts can have atmost a single unique ar,l-dressTwo for a router and none are really needed for a host26- consider the situation where a datagram of 4,000 bytes (where 20byres are of rhe ip heacier) arrives at a router that must forwar

  • 8/13/2019 PhD - Computer Science - 2010

    10/17

    u- 56A. The sender responds to a loss event by reducing its conges-tion window sizeB. The receiver does not drop excess packets but due to conges-tion does not forward themC. The receiver drops excess packets due to congestionD. To compensate for the loss event, sender doubles its conges-tion window size

    29. The amount of time required to read a block of data frour a diskinto memory is composed of seek time, rotational latencl', andtransfer time. Rotational latency refers toA. the time it takes for the platter to make a full rotationB. the time it takes for the read-write head to mor,-e into positionover the appropriate trackc. the time it takes for the platter to rotate the correct sectorunder the headD. None of the above30. According to the specifications of a particular hard clisk a seektakes 3 msecs between adjacent tracks. If the disk has 100 cvlin-ders how long will it take for the head to move from the innerrnostcylinder to the outermost cylinder?

    A. 30 mi,crosecondsB. 3000 rnsecsC. 3 microsecondsD. 300 rnsecs

    10

  • 8/13/2019 PhD - Computer Science - 2010

    11/17

    U- 5L

    31.

    For Questions 31 and 32, use the following table.

    The Principal Disjunctive Normal Form (DNF) for f (p,g, r) gir-enin the table is: (Note: I means not-of-A)A. Fqr+pqr*pQrB. pqr+pqr*pQrC. pqr+Fqr+pqrD. pqr+Fqr*pQrThe simplified equivalent logical expression for g(p,g, r) is:A. (p*- qrB. (p-, qrC. (p** qrD. (p*' qr

    33. which of the following is (are) TRUE about 'irtual rnemor\: s\rs_tems that use pages?I. The virtual address space can be larger than the amonnt ofphysical memory.il. Programs must be resident in main memory throughciut theirexecution.rII. Pages correspond to semantic characteristics of the pro-gram.

    32.

    p q r f (p, q, r) g(p, q,r)11110000

    11001100

    10101010

    00100i10

    11100111

    11

  • 8/13/2019 PhD - Computer Science - 2010

    12/17

    u -'- 5bI onlyII onlyI and III and III

    A certain pipelined RISC machine has 8 general-purpose registersRA, RI,. . . , RT and supports the following operations.ADD Rs1,Rs2,Rd :Add Rs1 & Rs2 and put the sum in RdMUL Rs1,Rs2,Rd :Multiply Rs1 & Rs2 a:rd product in Rd

    An operation normally takes one cycle; however, an operationtakes two cycles if it produces a result required by the immedi-ately following operation in an operation sequence. Consider theexpression AB + ABC + BC,where variables A, B,C are locatedin registers "R0, Rl, R.2. If the contents of these three registersmust not be modified, what is the minimum number of clock cy-cles required for an operation sequence that computes the valueof AB + ABC + BC?A.58.6c.7D.8Wrich of the following statement(s) is f arc TRUtr:I. Deterministic finite automaton has the same po\\.er as tirenon-deterministic finite automaton.n. Deterministic push down automaton has the same power asthe non-deterministic push down automaton.III. Deterministic turing machine has the same power as norl-deterministic turing machine.

    A.B,C.D.

    34.

    otrt)tJ.

    12

  • 8/13/2019 PhD - Computer Science - 2010

    13/17

    U-s6A. I, II and IIIB. I onlyC. I and III onlyD. I and II only

    36. The uon Neumann bottleneck arises due toA. mismatch in speed between secondary and primary storageB. mismatch in speed between cpu and primary storageC. slow speed of I/O devicesD. low clock speeds

    37. Accessing disk storage is slower than accessing RAM by an orderofA. 10B. 100c. 1000D. 100,000After reading the following passage, choose the best answer toeach question. Answer questions 38 - 40 following the passage onthe basis of what is stated or implied in the passage.An essay which appeals chiefly to the intellect is Francis Bacon's"of studies." His careful tripartite division of studies expressedsuccinctly in aphoristic prose demands the complete attention ofthe reader. He considers studies as they should be: for pleasurc,for self-improvement, for business. He considers the evils of excessstudy: laainess, affectation, and precocity. Bacon divides booksinto three categories: those to be read in part, those to be reacl. cursorilg and those to be read with care. Studies should incluclereading, which gives depth; speaking, which adds readiness of

    13

  • 8/13/2019 PhD - Computer Science - 2010

    14/17

    38.

    39.

    40.

    u' - 56thought; and writing, which trains preciseness. somewhat nris-takenly, the author ascribes certain virtues to individual fieldsof study: wisdom to history, wit to poetry, subtlety to mathe-matics, and depth to natural philosophy. Bacon,s four-hundred-word essay, studded with Latin phrases and highly compressed inthought, has intellectual appeal indeed.which of the following is the most appropriate title for the pas-sage, based on its content?A. Flancis Bacon and the Appeal of the EsayB. "Of Studies": A Tbipartite DivisionC. An Intellectual Exercise: Francis Bacon,s ,,Of Studies,'D. The Categorization of Books According to BaconAccording to the passage, who has mistakenly ascribed certainvirtues to individual fields of study.A. Scholars of the SocietyB. General ReaderC. The author of the passageD. Fbancis BaconThe passage suggests that the author would be most likely toagree with which of the following statements?A. "Of Studies" belongs in the category of works that demandto be read with care.B. Scholars' personalities are shaped by the academic disciplinein which they are engaged.c. An author can be more persuasive in a long essay tharr i' ashorter one.D. It is an a.ffectation to use foreign words in one's writing.

    T4

  • 8/13/2019 PhD - Computer Science - 2010

    15/17

    u- s-6

    PART B: sHoRT ANSwER euESTroNS (20 Marks)Answer any FrVE Questions. Each Quest'ion carries Four Marks1. Given a list of numbers, for each of the operations listed below,briefly describe an algorithm to implement it and state the algo-rithm's asymptotic time complexity.

    (a) Find the minimum value of the list.(b) Compute the arithmetic mean(c) Find the mode (the element that is repeated the most).

    2. Let G be an undirected graph with 100 vertices numbered 1 to100. Two vertices e and j are adjacent rt li- jl: 6 or li,- jl: 10.What is the number of connected components in G? (Hint: Lookat the connected edges in the adjacency matrix, ignoring anybridges between the two sets).3. TCP uses a timeout / retransmit mechanism to recover from lostsegments. Bxplain the essential concepts of how this timeontvalue may be estimated.

    4. Consider the grarnmar G whose productions are: S -t ^9b,S I a(a) Does the string abababa belong to the language generated bythe grammar G?(b) Is the grammar G ambiguous? Justify your answers.

    5. What is the value of ft after the following pseudocode has beenexecuted? Please justify your answer clearly.k :0;forh: lton,

    f or iz : L to 'i'1,f ori* : L to i*-1k_k+1;

  • 8/13/2019 PhD - Computer Science - 2010

    16/17

    u --56

    6. Obtain a minimum spanning forest for the foliowing weightedundirected graph represented by the 10 x 10 matrix A (0 indi-cates there is no edge).

    A:

    7. Write a boolean expression that is equivalent to the circuit di-agram given in Figure 1. Please show the intermediate stepsclearly.

    Figure 1: Circuit Diagram

    0044500000002530000042401000004503500000531500000000000005340000000722000005703200000323210000042218

    16

  • 8/13/2019 PhD - Computer Science - 2010

    17/17

    U,-sb

    PART C: LONG ANSWER QUESTION (10 Marks)write a program in C for implementing a Binary Search Tree (BST)data structure. Your program should have Insert, Delete and" Fin,r]functions as well as function(s) to read a file that conta,ins onern,tionson the BST in the following format: Funct'ion Value.. An example ofa file shorvn below:

    Insert 20Insert 10Delete 20Insert 30Find 10I. Give the code of functions for operations on BST.II. Give the code of function(s) for handling the input text file ancluo.rrr. Show the output of your program after each line for the examplctext file given above.PARJT D: (5 Marks)

    1. The following questions pertain to your research interest. Answerbriefly and to-the-point.a. State your topic of research interest.b. Why do you choose to do research on this topic?c. Mention an important research publication you have studieclin this research area. What is the contribution of this paper?d. What are the potential applications of this research?e. How do you think your education, training and experiencehelp you do research in the area you have chosen?

    17