Welcome to BrainDen.com - Brain Teasers Forum

 Welcome to BrainDen.com - Brain Teasers Forum. Like most online communities you must register to post in our community, but don't worry this is a simple free process. To be a part of BrainDen Forums you may create a new account or sign in if you already have an account. As a member you could start new topics, reply to others, subscribe to topics/forums to get automatic updates, get your own profile and make new friends. Of course, you can also enjoy our collection of amazing optical illusions and cool math games. If you like our site, you may support us by simply clicking Google "+1" or Facebook "Like" buttons at the top. If you have a website, we would appreciate a little link to BrainDen. Thanks and enjoy the Den :-)
Guest Message by DevFuse

Get final status from the drawing sequence

2 replies to this topic

#1 Benson

Benson

Junior Member

• Members
• 23 posts

Posted 27 September 2007 - 04:00 PM

There are 4 balls marked as "A", "B", "C" and "D" in the order. So, randomly draw one out and then put it back to the
next draw position. For example,
CABD -> 3 (B)
BACD -> 4 (D)
DACB -> 2 (A)

So, the question is, how to calculate the final stage with a given draw sequence with minimum draw simulation?
• 0

#2 bonanova

bonanova

bonanova

• Moderator
• 6161 posts
• Gender:Male
• Location:New York

Posted 28 September 2007 - 06:34 AM

There are 4 balls marked as "A", "B", "C" and "D" in the order. So, randomly draw one out and then put it back to the
next draw position. For example,
CABD -> 3 (B)
BACD -> 4 (D)
DACB -> 2 (A)

So, the question is, how to calculate the final stage with a given draw sequence with minimum draw simulation?

OK. It looks like what you do is

[1] remove a ball at random
[2] re-arrange the other balls into their original order [e.g. ACD in line 3] but ... not ACB in the last line. I don't get that part.
[3] replace the removed ball at the beginning [left end] of the line.

OK now what are you asking? Can you rephrase it or give an example? Thanks.
• 0

Vidi vici veni.

#3 Benson

Benson

Junior Member

• Members
• 23 posts

Posted 28 September 2007 - 06:48 AM

[2] re-arrange the other balls into their original order [e.g. ACD in line 3] but ... not ACB in the last line. I don't get that part.

-> the "C" put "back" to "B"'s position in line 3 and "B" put "back" to "D"'s position in the last line.

OK now what are you asking? Can you rephrase it or give an example? Thanks.

For example,
2,3,1,4,1,2,4,3,1,3,2,2,4

How to quickly get the final sequence is: