Question
Which sorting algorithm is the most efficient for large
datasets and uses a divide-and-conquer approach?Solution
Merge Sort is a divide-and-conquer algorithm that divides the dataset into smaller subarrays, sorts each recursively, and merges them back to form a sorted array. Its time complexity is O(n log n) in all cases, making it highly efficient for large datasets.Advantages of Merge Sort include:
- Stability: It maintains the order of equal elements.
- Predictable performance: Consistent time complexity across best, worst, and average cases.
- Handles large datasets effectively, especially when external memory (e.g., disk storage) is involved.
Suresh said that he had been cleaning his room when it started raining.
The officer ordered the fellow to be arrested.
Choose the option that is the direct form of the sentence.
He asked me to wait there until I got my turn.
The groom said to the bride, "I will take good care of you."
Select the correct direct form of the given sentence.
Shyam asked me how I had persuaded his sister.
Ram said,"Are you really serious about becoming a pilot, son?"
Mother needs your help in the kitchen.
She said, " I really wish I had bought that new car."
Select the correct indirect/direct speech for the given sentence
Sarita said that she might go home the next day with her mother.
...The manager said "Vivek must go tomorrow to meet the client".