If order doesn't matter then you need to work out the number of combinations
of each size, e.g., how many single phrases, how many double phrases, etc.
upto how many 8 phrases.
In theory this is done using nCr = (n!)/(r!(n-r)!)
So for example, the number of three phrase combinations out of the eight
phrases is 8C3 = (8!)/(3!5!) = 56.
Some light shed on the theory but not the practice, I'm afraid.
----- Original Message -----
From: "Allcock, Neil" <[log in to unmask]>
To: <[log in to unmask]>
Sent: Friday, December 14, 2001 4:34 PM
Subject: every possible combination of array
> Hello there,
> Is there a quick way to get every possible combination of this list:
> Consist, Train Formation, Loco, Yard, Route, Timings, Traincrew, Remarks
> Train Formation
> Consist, Route, Remarks
> Loco, Timings
> Information contained in this message is confidential and may be legally
> privileged and is intended for the addressee only. If you have received
> message in error or there are any problems please notify the originator
> The unauthorised use, disclosure, copying or alteration of this message is
> strictly forbidden. The mail and any attachments have been scanned for
> viruses prior to leaving English, Welsh & Scottish Railway's Ltd's (EWS)
> network. EWS Ltd will not be liable for direct, special, indirect or
> consequential damages arising from alteration of the contents of this
> message by a third party or as a result of any virus being passed on.
> Internet e-mails are not necessarily secure. EWS does not accept
> responsibilty for changes to any e-mail which occur after it is sent. For
> more information about EWS Ltd, please see our website:-
> English Welsh & Scottish Railway Limited
> Registered Office: 310 Goswell Road London EC1V 7LW.
> Registered in England and Wales - Registered No : 2938988