.
  Vyom World.com . Let's Touch the Sky Together!  
.

Home
VyomWorld.com Home
Interview Questions
VyomLinks.com Home
JobsAssist.com Home
Vyom Network
Contact Us
Jobs & Careers
Resume Submitter
Placement Papers
IT Companies Directory
Computer Jobs
Interview Questions
Online Exams
Vyom Career eMag.
Fun
Send FREE SMS!
SMS Jokes
Source Codes Library
Source Codes Home
ASP Source Codes
C Source Codes
C++ Source Codes
COBOL Source Codes
Java Source Codes
Pascal Source Codes
Submit Source Codes
GATE
GATE an Overview
GATE Preparation
Study Materal
GRE
GRE an Overview
GRE Questions
GRE Preparation
GRE Universities
TOEFL Preparation
TOEFL Resources
GMAT Preparation
GMAT Resources
MBA Preparation
MBA Resources
Networking Concepts
Networking Concepts
Testing Preparation
Testing Resources
Webmasters
Free Traffic Builder
Webmaster Articles
Web Hosting
Tutorials
Hardware Tutorial
1500 Free eBooks New!


Home » Placement Papers » Texas Placement Papers » Texas Previous Year Placement Paper

 

Texas Placement Paper -: DATA STRUCTURES Questions And Answers


Advertisements
Advertisements




Texas Previous Years Solved Sample Placement Papers

  1. Choose the correct alternative for when global variables in different files are recognized:

    A. at compile time

    B. at loading time

    C. at linking time Answer: Option C

    D. at execution time

  2. Solution: Global variables in different files are linked during the linking phase, making them accessible across files.
  3. Choose the correct alternative for the size of an `int`:

    A. always 2 bytes

    B. depends on the compiler being used Answer: Option B

    C. always 32 bits

    D. can't tell

  4. Solution: The size of an `int` depends on the platform and compiler, typically 2 or 4 bytes.
  5. Identify which program will overflow given the two programs:

    A. Program 1

    B. Program 2

    C. Both 1 & 2

    D. None Answer: Option C

  6. Solution: Both programs contain logic that could lead to stack or variable overflow during execution, depending on the input.
  7. Variables of a function call are allocated in:

    A. registers and stack Answer: Option A

    B. registers and heap

    C. stack and heap

    D. None

  8. Solution: Function call variables are allocated in the stack, while registers may hold temporary values for faster access.
  9. What is the average and worst-case time complexity of a sorted binary tree?

    A. O(log n), O(n) Answer: Option A

    B. O(log n), O(log n)

    C. O(n), O(n)

    D. O(n), O(log n)

  10. Solution: In a sorted binary tree, the average case is O(log n), while the worst case (skewed tree) is O(n).
  11. The data structure used for a priority queue is:

    A. Linked list

    B. Doubly linked list

    C. Array

    D. Tree Answer: Option D

  12. Solution: Trees, such as heaps, are commonly used for implementing priority queues due to their efficient access and modification times.
  13. Output of the program:
    main() { char str[5] = "hello"; if (str == NULL) printf("string null"); else printf("string not null"); }

    A. String is null

    B. String is not null Answer: Option B

    C. Error in program

    D. It executes but prints nothing

  14. Solution: The condition `str == NULL` will never be true since `str` is a valid memory address.
  15. Choose the best bucket size for hashing:

    A. 100

    B. 50

    C. 21

    D. 32 Answer: Option D

  16. Solution: The number of buckets should be chosen as a power of 2 for efficient hashing.
  17. Output of the program:
    void f(int *p) { static val = 100; val = &p; } main() { int a = 10; printf("%d ", a); f(&a); printf("%d ", a); }

    A. 10, 10 Answer: Option A

    B. 10, 0

    C. Error

    D. Undefined behavior

  18. Solution: The program does not modify the variable `a`, so it prints `10` twice.
  19. Given the following code:
    main() { char a[10] = "hello"; strcpy(a, '\0'); printf("%s", a); }

    A. String is null

    B. String is not null

    C. Program error

    D. Answer: Program error

  20. Solution: The `strcpy` function expects a valid string, but `'\0'` is a character constant, leading to a program error.




 


.

Recently Updated: New Placement Papers added.
Vyom Network : Web Hosting | Dedicated Server | Free SMS, GRE, GMAT, MBA | Online Exams | Freshers Jobs | Software Downloads | Programming & Source Codes | GRE Preparation | Jobs, Discussions | Software Listing | Free eBooks | Free eBooks | Free Business Info | Interview Questions | Free Tutorials | International Business Information | IAS Preparation | Jokes, Songs, Fun | Free Classifieds | Free Recipes | FAQs | Free Downloads | Bangalore Info | Tech Solutions | Project Outsourcing, Web Hosting | GATE Preparation | MBA Preparation | SAP Info | Excellent Mobiles | Software Testing | Interview Questions | Freshers Jobs | Server Insiders | File Extension Directory

Copyright ©2003-2024 Vyom Technosoft Pvt. Ltd., All Rights Reserved. Read our Privacy Policy