- Type
- Final term past paper
- Course
- CS301 Data Structures
- Size
- PDF 2.2 MB
- Updated
- 23 Oct 2026
You get 3 free files a day on the website. Add the Chrome extensionSign in with the extension for 30 a day.
Preview text
Text from pages 2, 3, 4 of 45. Download the file for all 45 pages.
Q1. A solution is said to be efficient if it solves the problem within its resource constraints i.e. hardware and time. (1 marks)
Correct answer: True (Page 4)
Q2. Which one of the following is known as "Last-In, First-Out" or LIFO Data Structure? (1 marks)
Correct answer: Stack (Page 54)
Q3. What will be postfix expression of the following infix expression? (1 marks)
Infix Expression : a+b*c-d
Correct answer: abc*+d-
Q4. For compiler a postfix expression is easier to evaluate than infix expression? (1 marks)
Q5. Consider the following pseudo code (1 marks)
declare a stack of characters while ( there are more characters in the word to read ) read a character push the character on the stack
while ( the stack is not empty )
pop a character off the stack write the character to the screen
What is written to the screen for the input "apples"?
Correct answer: selppa
Q6. Consider the following function: (1 marks)
void test_a(int n)
cout << n << " "; if (n>0) test_a(n-2);
What is printed by the call test_a(4)?
Correct answer: 4 2
Q7. If there are N external nodes in a binary tree then what will be the no. of internal nodes in this binary tree? (1 marks)
Correct answer: N -1 (Page 304)
Q8. If there are N internal nodes in a binary tree then what will be the no. of external nodes in this binary tree? (1 marks)
Correct answer: N +1 (Page 303)
Q9. If we have 1000 sets each containing a single different person. Which of the following relation will be true on each set: (1 marks)
Correct answer: Reflexive (page 387)
Q10. Which one of the following is NOT the property of equivalence relation: (1 marks)
Correct answer: Associative (page 387)
Q11. A binary tree of N nodes has _______. (1 marks)
Correct answer: Log2 N levels (Page 212)
Q12. The easiest case of deleting a node from BST is the case in which the node to be deleted ___________. (1 marks)
Correct answer: Is a leaf node (Page 173)
Q13. If there are N elements in an array then the number of maximum steps needed to find an element using Binary Search is _______ . (1 marks)
Correct answer: log2N (page 440)
Q14. Merge sort and quick sort both fall into the same category of sorting algorithms. What is this category? (1 marks)
Correct answer: None of the given options. (Page 488)
Related CS301 files
All CS301 files →- CS301 Final Term Quiz 4 Jan 2024 by Miss Mehwish Final term PDF 420 KB
- CS301 Final Term Slides Lectures 19-45 Final term PDF 9.5 MB
- CS301 Final Term Solved Subjective with References by Moaaz Final term PDF 625 KB
- CS301 Final Term Past Papers File 1 Set 2 by Waqar Siddhu Final term PDF 3.6 MB
- CS301 Highlighted Notes Set 2 Highlighted PDF 1.1 MB
- CS301 Quiz 1 Lectures 1-8 Quiz PDF 2.5 MB
Get more out of VUBuddy, for free
- Unlimited downloads
- The explanation behind every MCQ answer
- Study offline on slow data
- 30 downloads a day instead of 3
- Sign in and buy Pro Semester here
One Pro Semester membership works in both the extension and the app.