math combinations

new topic     » topic index » view thread      » older message » newer message

This is a multi-part message in MIME format.

------=_NextPart_000_001C_01C20532.A5A9D670
	charset="iso-8859-2"

How would I write a routine which would shuffle all members in a =
sequence so that all possible combinations would be gotten?
Also, input sequence could have two or more equal members.

For example, all combinations for {'a','b','c'} would be:
{'a','b','c'}
{'a','c','b'}
{'b','a','c'}
{'b','c','a'}
{'c','b','a'}



------=_NextPart_000_001C_01C20532.A5A9D670
Content-Type: text/html;
	charset="iso-8859-2"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-2">
<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>How would I write a routine which would =
shuffle all=20
members in a sequence so that&nbsp;all possible combinations would be=20
gotten?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Also, input sequence could have two or =
more equal=20
members.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>For example, all combinations for =
{'a','b','c'}=20
would=20
be:<BR>{'a','b','c'}<BR>{'a','c','b'}<BR>{'b','a','c'}<BR>{'b','c','a'}<B=
R>{'c','b','a'}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>

------=_NextPart_000_001C_01C20532.A5A9D670--

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu