OneStopGate.Com
OnestopGate   OnestopGate
   Sunday, November 24, 2024 Login  
OnestopGate
Home | Overview | Syllabus | Tutorials | FAQs | Downloads | Recommended Websites | Advertise | Payments | Contact Us | Forum
OneStopGate

GATE Resources
Gate Articles
Gate Books
Gate Colleges 
Gate Downloads 
Gate Faqs
Gate Jobs
Gate News 
Gate Sample Papers
Training Institutes

GATE Overview
Overview
GATE Eligibility
Structure Of GATE
GATE Coaching Centers
Colleges Providing M.Tech/M.E.
GATE Score
GATE Results
PG with Scholarships
Article On GATE
Admission Process For M.Tech/ MCP-PhD
GATE Topper 2012-13
GATE Forum




GATE 2025 Exclusive
Organizing Institute
Important Dates
How to Apply
Discipline Codes
GATE 2025 Exam Structure

GATE 2025 Syllabus
Aerospace Engg..
Agricultural Engg..
Architecture and Planning
Chemical Engg..
Chemistry
Civil Engg..
Computer Science / IT
Electronics & Communication Engg..
Electrical Engg..
Engineering Sciences
Geology and Geophysics
Instrumentation Engineering
Life Sciences
Mathematics
Mechanical Engg..
Metallurgical Engg..
Mining Engg..
Physics
Production & Industrial Engg..
Pharmaceutical Sciences
Textile Engineering and Fibre Science

GATE Study Material
Aerospace Engg..
Agricultural Engg..
Chemical Engg..
Chemistry
Civil Engg..
Computer Science / IT
Electronics & Communication Engg..
Electrical Engg..
Engineering Sciences
Instrumentation Engg..
Life Sciences
Mathematics
Mechanical Engg..
Physics
Pharmaceutical Sciences
Textile Engineering  and Fibre Science

GATE Preparation
GATE Pattern
GATE Tips N Tricks
Compare Evaluation
Sample Papers 
Gate Downloads 
Experts View

CEED 2013
CEED Exams
Eligibility
Application Forms
Important Dates
Contact Address
Examination Centres
CEED Sample Papers

Discuss GATE
GATE Forum
Exam Cities
Contact Details
Bank Details

Miscellaneous
Advertisment
Contact Us


Home » Gate Sample Papers » Computer Science + IT Engineering Sample Papers » GATE Download Sample Question Papers GATE – Sample Questions - CSE2

GATE Download Sample Question Papers GATE – Sample Questions - CSE2

1 Consider the following C function void swap (int a, int b) { int temp ; temp = a ; a = b ; b = temp ; } In order to exchange the values of two variables x and y. Options A) call swap (x, y) B) call swap (&x, &y) C) swap (x, y) cannot be used as it does not return any value D) swap (x, y) cannot be used as the parameters are passed by value Your Answer ( Not Answered ) Correct Answer B 2 A 5 stage pipelined CPU has the following sequence of stages: IF - Instruction fetch from instruction memory, RD - Instruction decode and register read, EX - Execute: ALU operation for data and address computation, MA - Data memory access - for write access, the register read at RD stage is used, WB - Register write back. Consider the following sequence of instructions: I 1 : L R0, 1oc1; R0 <= M[1oc1] I 2 : A R0, R0; R0 <= R0 + R0 I 3 : A R2, R0; R2 <= R2 - R0 Let each stage take one clock cycle. What is the number of clock cycles taken to complete the above sequence of instructions starting from the fetch of I 1 ? Options A) 8 B) 10 C) 12 D) 15 Your Answer ( Not Answered ) Correct Answer A 3 The address resolution protocol (ARP) is used for Options A) Finding the IP address from the DNS B) Finding the IP address of the default gateway C) Finding the IP address that corresponds to a MAC address D) Finding the MAC address that corresponds to an IP address Your Answer ( Not Answered ) Correct Answer D 4 Consider the following relation schema pertaining to a students database: Student ( rollno , name, address) Enroll ( rollno , courseno , coursename) where the primary keys are shown underlined. The number of tuples in the Student and Enroll tables are 120 and 8 respectively. What are the maximum and minimum number of tuples that can be present in (Student * Enroll), where '*'denotes natural join? Options A) 8, 8 B) 120, 8 C) 960, 8 D) 960, 120 Your Answer ( Not Answered ) Correct Answer C 5 Consider a direct mapped cache of size 32 KB with block size 32 bytes. The CPU generates 32 bit addresses. The number of bits needed for cache indexing and the number of tag bits are respectively Options A) 10, 17 B) 10, 22 C) 15, 17 D) 5, 17 Your Answer ( Not Answered ) Correct Answer A 6 Which one of the following is a key factor for preferring B + -trees to binary search trees for indexing database relations? Options A) Database relations have a large number of records B) Database relations are sorted on the primary key C) B + -trees require less memory than binary search trees D) Data transfer from disks is in blocks Your Answer ( Not Answered ) Correct Answer D 7 The goal of structured programming is to Options A) have well indented programs B) be able to infer the flow of control from the compiled code C) be able to infer the flow of control from the program text D) avoid the use of GOTO statements Your Answer ( Not Answered ) Correct Answer C 8 The tightest lower bound on the number of comparisons, in the worst ease, for comparison-based sorting is of the order of Options A) n B) n 2 C) n log n D) n log 2 n Your Answer ( Not Answered ) Correct Answer B 9 Consider the following two problems on undirected graphs a: Given G(V, E), does G have an independent set of size |V| -4? b: Given G(V, E), does G have an independent set of size 5? Which one of the following is TRUE? Options A) a is in P and b is NP-complete B) a is NP-complete and b is in P C) Both a and b are NP-complete D) Both a and b are in P Your Answer ( Not Answered ) Correct Answer C 10 Consider the languages L 1 = {ww R | w Î {0, 1}*} L 2 = {w# w R | w Î {0, 1}*}, where # is a special symbol L 3 = {ww | w Î {0, 1}*} Which one of the following is TRUE? Options A) L 1 is a deterministic CFL B) L 2 is a deterministic CFL C) L 3 is a CFL, but not a deterministic CFL D) L 3 is a deterministic CFL Your Answer ( Not Answered ) Correct Answer B 11 Let G be a simple graph with 20 vertices and 100 edges. The size of the minimum vertex cover of G is 8. Then, the size of the maximum independent set of G is Options A) 12 B) 8 C) Less than 8 D) More than 12 Your Answer ( Not Answered ) Correct Answer A 12 A and B are the only two stations on an Ethernet. Each has a steady queue of frames to send. Both A and B attempt to transmit a frame, collide, and A wins the first backoff race. At the end of this successful transmission by A, both A and B attempt to transmit and collide. The probability that A wins the second backoff race is Options A) 0.5 B) 0.625 C) 0.75 D) 1.0 Your Answer ( Not Answered ) Correct Answer A 13 Consider the grammar E ® E + n | E x n | n For a sentence n + n x n, the handles in the right-sentential form of the reduction are Options A) n, E + n and E + n x n B) n, E + n and E + E x n C) n, n + n and n + n x n D) n, E + n and E x n Your Answer ( Not Answered ) Correct Answer D 14 Consider the grammar with the following translation rules and E as the start symbol. E ® E 1 # T {E.value = E 1 .value * T.value } | T {E.value = T.value } T ® T 1 & F { T.value = T 1 .value + F.value } | F {T.value = F.value} F ® num {F.value = num.value } Compute E. value for the root of the parse tree for the expression: 2 # 3 & 5 # 6 & 4. Options A) 200 B) 180 C) 160 D) 40 Your Answer ( Not Answered ) Correct Answer C 15 Let A be a sequence of 8 distinct integers sorted in ascending order. How many distinct pairs of sequences, B and C are there such that (i) each is sorted in ascending order, (ii) B has 5 and C has 3 elements, and (iii) the result of merging B and C gives A? Options A) 2 B) 30 C) 56 D) 256 Your Answer ( Not Answered ) Correct Answer D 16 Which one of the following is true for a CPU having a single interrupt request line and a single interrrupt grant line? Options A) Neither vectored interrupt nor multiple interrupting devices are possible. B) Vectored interrupts are not possible but multiple interrupting devices are possible. C) Vectored interrupts and multiple interrupting devices are both possible. D) Vectored interrupt is possible but multiple interrupting devices are not possible. Your Answer ( Not Answered ) Correct Answer B 17 Consider a relation scheme R = (A, B, C, D, E, H) on which the following functional dependencies hold : (A ® B, BC ® D, E ® C, D ® A). What are the candidate keys of R? Options A) AE, BE B) AE, BE, DE C) AEH, BEH, BCH D) AEH, BEH, DEH Your Answer ( Not Answered ) Correct Answer D 18 In a network of LANs connected by bridges, packets are sent from one LAN to another through intermediate bridges. Since more than one path may exist between two LANs, packets may have to be routed through multiple bridges. Why is the spanning tree algorithm used for bridge-routing? Options A) For shortest path routing between LANs B) For avoiding loops in the routing paths C) For fault tolerance D) For minimizing collisions Your Answer ( Not Answered ) Correct Answer B 19 Suppose T(n) = 2T (n/2) + n, T(0) = T(1) = 1 Which one of the following is FALSE? Options A) T(n) = O(n 2 ) B) T(n) = q (n log n) C) T(n) = W (n 2 ) D) T(n) = O(n log n) Your Answer ( Not Answered ) Correct Answer B 20 Consider the following C program segment struct CellNode { struct CellNode *leftChild ; int element; struct CellNode *rightChild ; }; int DoSomething (struct CellNode *ptr) { int value = 0 ; if (ptr ! = NULL) { if (ptr->leftChild ! = NULL) value = 1 + DoSomething (ptr - > leftChild) ; if (ptr - > rightChild ! = NULL) value = max (value, 1 + DoSomething (ptr - > rightChild)) ; } return (value); } The value returned by the function DoSomething when a pointer to the root of a non-empty tree is passed as argument is Options A) The number of leaf nodes in the tree B) The number of nodes in the tree C) The number of internal nodes in the tree D) The height of the tree Your Answer ( Not Answered ) Correct Answer D



More Computer Science + IT Engineering Sample Papers





Discussion Center

Discuss/
Query

Papers/
Syllabus

Feedback/
Suggestion

Yahoo
Groups

Sirfdosti
Groups

Contact
Us

MEMBERS LOGIN
  
Email ID:
Password:

  Forgot Password?
 New User? Register!

INTERVIEW EBOOK
Get 9,000+ Interview Questions & Answers in an eBook. Interview Question & Answer Guide
  • 9,000+ Interview Questions
  • All Questions Answered
  • 5 FREE Bonuses
  • Free Upgrades
GATE RESOURCES
 
  • Gate Books
  • Training Institutes
  • Gate FAQs
  • GATE BOOKS
     
  • Mechanical Engineeering Books
  • Robotics Automations Engineering Books
  • Civil Engineering Books
  • Chemical Engineering Books
  • Environmental Engineering Books
  • Electrical Engineering Books
  • Electronics Engineering Books
  • Information Technology Books
  • Software Engineering Books
  • GATE Preparation Books
  • Exciting Offers



    GATE Exam, Gate 2009, Gate Papers, Gate Preparation & Related Pages


    GATE Overview | GATE Eligibility | Structure Of GATE | GATE Training Institutes | Colleges Providing M.Tech/M.E. | GATE Score | GATE Results | PG with Scholarships | Article On GATE | GATE Forum | GATE 2009 Exclusive | GATE 2009 Syllabus | GATE Organizing Institute | Important Dates for GATE Exam | How to Apply for GATE | Discipline / Branch Codes | GATE Syllabus for Aerospace Engineering | GATE Syllabus for Agricultural Engineering | GATE Syllabus for Architecture and Planning | GATE Syllabus for Chemical Engineering | GATE Syllabus for Chemistry | GATE Syllabus for Civil Engineering | GATE Syllabus for Computer Science / IT | GATE Syllabus for Electronics and Communication Engineering | GATE Syllabus for Engineering Sciences | GATE Syllabus for Geology and Geophysics | GATE Syllabus for Instrumentation Engineering | GATE Syllabus for Life Sciences | GATE Syllabus for Mathematics | GATE Syllabus for Mechanical Engineering | GATE Syllabus for Metallurgical Engineering | GATE Syllabus for Mining Engineering | GATE Syllabus for Physics | GATE Syllabus for Production and Industrial Engineering | GATE Syllabus for Pharmaceutical Sciences | GATE Syllabus for Textile Engineering and Fibre Science | GATE Preparation | GATE Pattern | GATE Tips & Tricks | GATE Compare Evaluation | GATE Sample Papers | GATE Downloads | Experts View on GATE | CEED 2009 | CEED 2009 Exam | Eligibility for CEED Exam | Application forms of CEED Exam | Important Dates of CEED Exam | Contact Address for CEED Exam | CEED Examination Centres | CEED Sample Papers | Discuss GATE | GATE Forum of OneStopGATE.com | GATE Exam Cities | Contact Details for GATE | Bank Details for GATE | GATE Miscellaneous Info | GATE FAQs | Advertisement on GATE | Contact Us on OneStopGATE |
    Copyright © 2024. One Stop Gate.com. All rights reserved Testimonials |Link To Us |Sitemap |Privacy Policy | Terms and Conditions|About Us
    Our Portals : Academic Tutorials | Best eBooksworld | Beyond Stats | City Details | Interview Questions | India Job Forum | Excellent Mobiles | Free Bangalore | Give Me The Code | Gog Logo | Free Classifieds | Jobs Assist | Interview Questions | One Stop FAQs | One Stop GATE | One Stop GRE | One Stop IAS | One Stop MBA | One Stop SAP | One Stop Testing | Web Hosting | Quick Site Kit | Sirf Dosti | Source Codes World | Tasty Food | Tech Archive | Software Testing Interview Questions | Free Online Exams | The Galz | Top Masala | Vyom | Vyom eBooks | Vyom International | Vyom Links | Vyoms | Vyom World
    C Interview Questions | C++ Interview Questions | Send Free SMS | Placement Papers | SMS Jokes | Cool Forwards | Romantic Shayari