?
Solved

i need a couple of code about MERGE SORT

Posted on 2001-06-14
3
Medium Priority
?
192 Views
Last Modified: 2010-05-02
Hi,
  i need  to merge sort code for visual basic. i want to arrange in order some random numerical value by merge sort algorithm. But i can't. Please help me.  Can you write to merge sort code  for VB?
  thanks......
0
Comment
Question by:firederik
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 3

Accepted Solution

by:
RodStephens earned 200 total points
ID: 6190942
Take a look at:

    http://www.vb-helper.com/howto/mergsort.zip

If you just want a general sorting algorithm and it doesn't have to be mergesort, you're probably better off using some other algorithm. Quicksort is usually faster. For an example, look at:

    http://www.vb-helper.com/howto/sort.zip

Depending on how your numeric data is arranged, countingsort and other algorithms may be much faster. I don't have examples of those posted but you can find them in my book "Ready-to-Run Visual Basic Algorithms" (http://www.vb-helper.com/vba.htm).
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7136143
Hi firederik@devx,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will suggest to:

    Accept RodStephens's comment(s) as an answer.

firederik@devx, if you think your question was not answered at all or if you need help, you can simply post a new comment here.  Community Support moderators will follow up.

EXPERTS: If you disagree with that recommendation, please post an explanatory comment.
==========
DanRollins -- EE database cleanup volunteer
0
 
LVL 1

Expert Comment

by:Computer101
ID: 7173335
Comment from expert accepted as answer

Computer101
E-E Moderator
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question