Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Generate all possible combinations from three data sets?


I want to build a table that lists all possible Blackjack initial han
combinations with a dealer and one player. This means I am onl
looking for the first 3 cards and I am making the assumption there is
full deck. So I have 3 sets of {2,3,4,5,6,7,8,9,10,J,Q,K,A} and ther
should be 2,197 possible combinations (suits are not considered). I
there an easy formula to generate all of the possible 2,197 hands?
Thanks

--
Flamike
-----------------------------------------------------------------------
Flamikey's Profile: http://www.excelforum.com/member.php...nfo&userid=461
View this thread: http://www.excelforum.com/showthread.php?threadid=26779

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,236
Default Generate all possible combinations from three data sets?

You want a permutation generator.

You could start with the one on J-Walk's site:
http://j-walk.com/ss/excel/tips/tip46.htm

With some work you might be able to get what you want.

--
Rob van Gelder - http://www.vangelder.co.nz/excel


"Flamikey" wrote in message
...

I want to build a table that lists all possible Blackjack initial hand
combinations with a dealer and one player. This means I am only
looking for the first 3 cards and I am making the assumption there is a
full deck. So I have 3 sets of {2,3,4,5,6,7,8,9,10,J,Q,K,A} and there
should be 2,197 possible combinations (suits are not considered). Is
there an easy formula to generate all of the possible 2,197 hands?
Thanks.


--
Flamikey
------------------------------------------------------------------------
Flamikey's Profile:
http://www.excelforum.com/member.php...fo&userid=4612
View this thread: http://www.excelforum.com/showthread...hreadid=267790



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 863
Default Generate all possible combinations from three data sets?

You need VBA for this.

Go to the Google news group search, and get the message posted by me (Myrna
Larson) on Aug 31, 2004 in the microsoft.public.excel.worksheet.functions
group. It includes the necessary VBA code and instructions as to how to use
it. On your worksheet, you will need to set up a 54-cell vertical range on the
worksheet with C in the 1st cell, 3 in the 2nd, and your list of 52 cards
below, i.e. 4 copies of the list you included in your message. The hands will
be listed on a new worksheet.

I calculate 22,100 combinations of 52 things taken 3 at a time. That's the
number of hands, assuming that suit DOES matter. Since it doesn't matter to
you, you can use Data/Filter/Advanced Filter on the list of 22,100 hands to
get the unique ones.


On Fri, 8 Oct 2004 16:45:07 -0500, Flamikey
wrote:


I want to build a table that lists all possible Blackjack initial hand
combinations with a dealer and one player. This means I am only
looking for the first 3 cards and I am making the assumption there is a
full deck. So I have 3 sets of {2,3,4,5,6,7,8,9,10,J,Q,K,A} and there
should be 2,197 possible combinations (suits are not considered). Is
there an easy formula to generate all of the possible 2,197 hands?
Thanks.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to create a macro in excel so that it can generate a list ofunique records using all permutations and combinations of the data in eachrow ad column Rizwan[_4_] Excel Discussion (Misc queries) 1 August 6th 09 01:44 PM
Combinations in a string of data Eán[_2_] Excel Worksheet Functions 4 February 27th 09 06:16 PM
Excel graph 3 sets of data. 2 sets as lines 1 as column? AndyN Charts and Charting in Excel 2 July 11th 08 01:18 PM
How to generate sets of random numbers without having duplicates William Excel Worksheet Functions 1 June 6th 06 05:30 AM
generate a random number and use if function to generate new data Dogdoc1142 Excel Worksheet Functions 4 April 26th 06 03:44 AM


All times are GMT +1. The time now is 05:59 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"