Click here to Skip to main content
15,914,350 members
Home / Discussions / Algorithms
   

Algorithms

 
AnswerRe: Iterating and comparing two Dictionary objects Pin
73Zeppelin9-May-08 7:52
73Zeppelin9-May-08 7:52 
AnswerRe: Iterating and comparing two Dictionary objects Pin
Alan Balkany9-May-08 10:33
Alan Balkany9-May-08 10:33 
AnswerRe: Iterating and comparing two Dictionary objects Pin
Mark Churchill18-May-08 4:40
Mark Churchill18-May-08 4:40 
GeneralRe: Iterating and comparing two Dictionary objects Pin
supercat924-May-08 15:12
supercat924-May-08 15:12 
Question(Possibly) Simple Maths Pin
Reelix9-May-08 0:51
Reelix9-May-08 0:51 
AnswerRe: (Possibly) Simple Maths Pin
Cedric Moonen9-May-08 1:08
Cedric Moonen9-May-08 1:08 
GeneralRe: (Possibly) Simple Maths Pin
Reelix9-May-08 2:14
Reelix9-May-08 2:14 
AnswerRe: (Possibly) Simple Maths Pin
Alan Balkany9-May-08 3:37
Alan Balkany9-May-08 3:37 
AnswerRe: (Possibly) Simple Maths Pin
CPallini9-May-08 4:20
mveCPallini9-May-08 4:20 
AnswerRe: (Possibly) Simple Maths Pin
73Zeppelin9-May-08 7:45
73Zeppelin9-May-08 7:45 
Questionneed similar to Excel's "Goal Seek" in C/C++ Pin
KimN6-May-08 9:04
KimN6-May-08 9:04 
AnswerRe: need similar to Excel's "Goal Seek" in C/C++ Pin
73Zeppelin6-May-08 9:17
73Zeppelin6-May-08 9:17 
GeneralRe: need similar to Excel's "Goal Seek" in C/C++ Pin
KimN6-May-08 10:06
KimN6-May-08 10:06 
GeneralRe: need similar to Excel's "Goal Seek" in C/C++ Pin
73Zeppelin6-May-08 10:29
73Zeppelin6-May-08 10:29 
AnswerRe: need similar to Excel's "Goal Seek" in C/C++ Pin
cp98766-May-08 15:57
cp98766-May-08 15:57 
GeneralRe: need similar to Excel's "Goal Seek" in C/C++ Pin
73Zeppelin6-May-08 19:19
73Zeppelin6-May-08 19:19 
QuestionSorting multiple lists so they are unique Pin
jrg20005-May-08 1:10
jrg20005-May-08 1:10 
AnswerRe: Sorting multiple lists so they are unique Pin
73Zeppelin6-May-08 9:19
73Zeppelin6-May-08 9:19 
GeneralRe: Sorting multiple lists so they are unique Pin
jrg20007-May-08 23:24
jrg20007-May-08 23:24 
GeneralRe: Sorting multiple lists so they are unique Pin
cp98768-May-08 20:06
cp98768-May-08 20:06 
AnswerRe: Sorting multiple lists so they are unique Pin
cp98766-May-08 20:40
cp98766-May-08 20:40 
GeneralRe: Sorting multiple lists so they are unique Pin
jrg20007-May-08 23:18
jrg20007-May-08 23:18 
AnswerRe: Sorting multiple lists so they are unique Pin
Andrew Rissing8-May-08 6:48
Andrew Rissing8-May-08 6:48 
GeneralRe: Sorting multiple lists so they are unique Pin
cp98768-May-08 11:52
cp98768-May-08 11:52 
Andrew Rissing wrote:
I would assume the best way, is the following.


This is a way, it may not be the best way. The reason is that it there is no guarantee that it will work. When you find a clash you make a decision as to what swap to make to resolve it. There are probably many ways to resolve each clash - you choose one. If you make the wrong choice your algorithm may get stuck (i.e you end up with a clash that you cannot resolve - all the elements you have left to swap with clash as well) - there is no way of backtracking in your algorithm to change those earlier choices. If you include backtracking to try all the choices you can make - then you have a simple exhaustive search.

Peter
"Until the invention of the computer, the machine gun was the device that enabled humans to make the most mistakes in the smallest amount of time."

AnswerRe: Sorting multiple lists so they are unique Pin
Cyrilix8-Jun-08 22:01
Cyrilix8-Jun-08 22:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.