Advanced QSAM Practice Questions
Advanced QSAM Practice Questions
SQL
1. Which of the following SQL clauses is used to combine rows from multiple queries?
A. UNION
B. INTERSECT
C. JOIN
D. ALL
C. INDEX column_name;
A. Executes a query
6. How would you select the top 5 employees with the highest salaries in SQL?
C. LEFT JOIN returns all rows from the left table, matched or not.
A. LEAD()
B. LAG()
C. ROW_NUMBER()
D. SUM() OVER()
A. NumPy
B. Pandas
C. Scikit-learn
D. Matplotlib
A. A loop
B. A function
C. A variable
D. A class
A. drop_duplicates()
B. unique()
C. remove_duplicates()
D. filter_duplicates()
B. Concatenates arrays
A. list(range(10))
B. (x for x in range(10))
C. [x for x in range(10)]
D. range(10)
A. 0 (row-wise)
B. 1 (column-wise)
C. None
A. NLTK
B. OpenCV
C. TensorFlow
D. Scikit-learn
A. Defines a generator
B. Ends a function
C. Returns a value
D. Creates a class
Algorithmics
1. What is the time complexity of the merge step in merge sort?
A. O(n^2)
B. O(n log n)
C. O(n)
D. O(log n)
A. Stack
B. Queue
C. Linked List
D. Hash Table
D. Both B and C.
4. Which graph traversal algorithm guarantees the shortest path in unweighted graphs?
A. Depth-First Search
B. Breadth-First Search
C. Dijkstra's Algorithm
D. Bellman-Ford
A. O(n)
B. O(log n)
C. O(1)
D. O(n^2)
A. Kruskal's Algorithm
B. Prim's Algorithm
C. Dijkstra's Algorithm
D. Bellman-Ford
A. O(n log n)
B. O(n)
C. O(n^2)
D. O(log n)
A. Bubble Sort
B. Merge Sort
C. N-Queens Problem
D. Quick Sort
Cognitive Ability
1. Which number replaces the question mark in the series: 5, 9, 17, 33, ?
A. 37
B. 49
C. 65
D. 41
A. 30 mph
B. 60 mph
C. 120 mph
D. 15 mph
A. 8
B. 12
C. 6
D. 16
A. Deviation
B. Standard
C. Unity
D. Similarity
A. 18
B. 20
C. 21
D. 24
A. Square
B. Triangle
C. Hexagon
D. Pentagon
7. What is the area of a rectangle with length 6 and width 3?
A. 12
B. 18
C. 24
D. 36
A. 9
B. 15
C. 19
D. 21
A. x > z
B. x = z
C. x < z
D. Cannot be determined
A. 90°
B. 180°
C. 360°
D. 120°
Answers
SQL
1. A
2. B
3. A
4. C
5. B
6. A
7. B
8. C
9. D
10. B
Python
1. B
2. B
3. A
4. A
5. B
6. A
7. A
8. A
9. A
10. A
Algorithmics
1. C
2. B
3. D
4. B
5. A
6. D
7. A
8. A
9. A
10. C
Cognitive Ability
1. C
2. A
3. B
4. A
5. C
6. B
7. B
8. C
9. A
10. B