AboutSyed Rizwan Muhammad Rizvi Expertise I can answers questions regarding web based and desktop based programming in VB.Net. Which can include SOAP, XML, Custom Controls, COM Interoperability etc.
Experience Have been working in this specific area for last 2 years previously I was a VB 6 Developer with experties in other languages as well. Total 10 years of programming experience.
Question I am looking for a fast way to randomly sort an array. The type of elements doesn't matter and the number of elements is variable. This will be a single dimensional array.
I have tried a basic bubble sort though with a large number of elements this becomes too slow. Any suggestions?
Answer Depending on your type and size of data there are various sorting mechanisms available that you can try e.g. Quick Sort, Heap Sort, Binary Sort, Sequential Sort.
Also, the array object has a built in Sort method, try using that you will find it very quick. Using the generic sort method makes your life a whole lot easier.