>Hi!
>
>Say I've got a list of calls I want to make in a day.
>
>Say I have ten calls, I want to work out every combination of order of visits.
>
>Has anyone any ideas on how I would achieve this?
>
>Any help extremley appreciated
First of all, you should be aware that the number of permutations increases rapidly - even worse than an exponential function.
For 10 calls, you have 10! = 1 * 2 * 3 * ... * 10 = 3628800 permutations.
For 30 calls, the number of calls is 30! = 2.65253E+32.
What you describe, I think, is called the "travelling salesman problem", and you can search algorithms for that. AFAIK, no algorithm exists that is optimal (guaranteed to give the optimal result) and that also gets the work done, in a reasonable time, but I think algorithms exist if you assume the triangular inequality (which is a sensible assumption for travel - the asumption being that for any three points A, B, and C, distance AC <= distance AB + distance BC). Also, near-optimal algorithms exist.
You can find more details at
http://en.wikipedia.org/wiki/Travelling_salesman_problem
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)