AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Deck of cards online random12/9/2023 ![]() ReDim lResults(1 To NO_OF_HANDS, 1 To lNoInHand) it should give you an idea of how to use the function in your own program.ĭim cNoCombinations As Currency, cCombinationNo As Currencyĭim lHand() As Long, lResults() As Long, lNoCards As Long, lNoInHand As Long, i As Long, j As Longĭim vSuits As Variant, vValues As Variant Here is an example macro which calls the function and "deals" a set of four hands (one at a time). MsgBox "Deck array is dimensioned incorrectly" If LBound(Deck) 1 Or UBound(Deck) 52 Then ![]() Is my Hands() code interacting in any strange way with the OneHand() code during the iterations to give me these strange results? Is the OneHand() code not as random as I think it is? I didn't create the OneHand() code, I found it online someplace, so if it's not random, I may need some help creating a better one. The bottom of the Hands() code just copies and pastes the results into a Master sheet, it shouldn't have anything to do with the actual iteration and randomization of the hands I'm seeing. Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
0 Comments
Read More
Leave a Reply. |