Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2007
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Quick Question

  • To: mathgroup at smc.vnet.net
  • Subject: [mg78101] Re: [mg78090] Quick Question
  • From: "Thomas Dowling" <thomasgdowling at gmail.com>
  • Date: Sat, 23 Jun 2007 07:01:53 -0400 (EDT)
  • References: <200706221050.GAA16639@smc.vnet.net>

Hello Rob,

listie =  {1,2,3,4,5,6}

With Mathematica 5.2, try:

<< DiscreteMath`Combinatorica`
RandomPermutation[listie]

giving ...

Out[3]= {1, 4, 5, 2, 3, 6}

With Mathematica 6:

< Combinatorica`
RandomPermutation[listie]



I presume this is what you want to do?

Thomas Dowling

On 6/22/07, rob cronin <cronin_rob at hotmail.com> wrote:
>
> Quick Question:
>
> With Mathematica 5.2 is there any way to scramble a simple list of
> numbers:
> i.e. randomly rearange the list {1,2,3,4,5,6} without any apparent order.
>
> Kind regards
>
> _________________________________________________________________
> Get a preview of Live Earth, the hottest event this summer - only on MSN
> http://liveearth.msn.com?source=msntaglineliveearthhm
>
>
>


  • References:
  • Prev by Date: StyleSheet Question
  • Next by Date: Re: Quick Question
  • Previous by thread: Re: Quick Question
  • Next by thread: Re: Quick Question