Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

A list is ordered from smaller to largest when a sort is
called. Which sort would take the shortest time to execute?

Answer Posted / sathyanarayana

Yes, its insertion sort. For a sorted array, it takes just
O(n) time. iTs mere traversal of an array as it is already
sorted. In the case of quick sort, it boils down to O(n^2)
in the case of sorted array.

Is This Answer Correct ?    5 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is data and data structure?

944


What are the categories of avl rotations?

981


What is static array?

952


What is entryset in hashmap?

898


Can we null keys in treemap?

993


What is minimum depth of binary tree?

958


Is any implicit arguments are passed to a function when it is called?

1008


What are the advantages of selecetion sort?

1084


What are the advantages of data structure?

952


What happens in insertion sort?

913


Tell me is it better to use a pointer to navigate an array of values, or is it better to use a subscripted array name?

914


Difference between hashset and treeset?

1045


Is array size dynamic or fixed?

947


What are doubly linked lists?

1012


What is a data structure? What are the types of data structures?

1033