**1. Who founded Python?**

- Alexander G. Bell
- Vincent Van Gogh
- Leonardo da Vinci
- Guido van Rossum

**Answer:**

**d. The idea of Python was conceived by Guido van Rossum in the later 1980s.**

**2. What is the type of programming language supported by Python?**

- Object-oriented
- Functional programming
- Structured programming
- All of the above

**Answer:**

**d. Python is an interpreted programming language, supporting object-oriented, structured, and functional programming.**

**3. Which among the following is the queue data structure’s applications?**

- When among the many or multiple users, a resource is shared.
- Balancing of the load.
- When the transferring of the data is asynchronous
- All of the above

**Answer:**

**4** All the above as all these features are the applications of queue type of data structure

**4. What is the time complexity of finding an element in a Python list using the** `**in**`

**operator?**

- O(n)
- O(log n)
- O(1)
- O(n^2)

**Answer:**

**A. O(n)**

Explanation: The `**in**`

operator in Python performs a linear search in a list, resulting in a time complexity of O(n) in the worst case.

**5. Which sorting algorithm has the best average-case time complexity in Python?**

- Quick Sort
- Merge Sort
- Bubble Sort
- Insertion Sort

**Answer:**

**A. Quick Sort**

Explanation: Quick Sort has an average-case time complexity of O(n log n), which makes it more efficient on average compared to the other sorting algorithms listed.

**6. What is the worst-case time complexity of the binary search algorithm in a sorted list of size n?**

- O(log n)
- O(n)
- O(1)
- O(n log n)

**Answer:**

**A. O(log n)**

Explanation: Binary search has a worst-case time complexity of O(log n) because it divides the search space in half with each comparison.

**7. Which algorithm is used to find the shortest path in a weighted directed graph with non-negative weights?**

- Depth-First Search (DFS)
- Breadth-First Search (BFS)
- Dijkstra's algorithm
- Kruskal's algorithm

**Answer:**

**C. Dijkstra's algorithm**

Explanation: Dijkstra's algorithm is used to find the shortest path in a weighted graph with non-negative weights.

**8. Which database term is used to describe the rules that govern the relationships between tables in a relational database?**

- Schema
- Index
- Query
- Constraints

**Answer:**

**D. Constraints**

Explanation: Constraints in a relational database define rules and relationships between tables, such as primary keys, foreign keys, and unique constraints.

**9. Which type of join returns only the rows that have matching values in both tables being joined?**

- INNER JOIN
- LEFT JOIN
- RIGHT JOIN
- FULL OUTER JOIN

**Answer:**

**A. INNER JOIN**

Explanation: INNER JOIN returns only the rows with matching values in both tables.

**10. In a relational database, what does ACID stand for?**

- Atomicity, Consistency, Isolation, Durability
- Association, Concurrency, Isolation, Dependency
- Atomicity, Concurrency, Isolation, Dependency
- Association, Consistency, Isolation, Durability

**Answer:**

**A. Atomicity, Consistency, Isolation, Durability**

Explanation: ACID stands for Atomicity, Consistency, Isolation, and Durability, which are properties that ensure the reliability of database transactions.

Module 4: Database Management and Warehousing

Top Tutorials

Related Articles

- Policies
- Privacy Statement
- Terms of Use

- Contact Us
- admissions@almabetter.com
- 08046008400

- Official Address
- 4th floor, 133/2, Janardhan Towers, Residency Road, Bengaluru, Karnataka, 560025

- Communication Address

- Follow Us

© 2024 AlmaBetter