from random import randint

num_reps = 1000000
accum = 0

Thresholds = [93,92,91,89,87,84,80,72,55,0]

for rep in range(num_reps):
	Deck = list(range(100)) # Cards from 0 to 99
	Hold = 100 # 100 is dummy value until we hold
	Highest = -1
	for deal in range(10):
		card = Deck.pop(randint(0,99-deal))
		if card > Highest:
			Highest = card
		if Hold == 100 and card >= Thresholds[deal]:
			Hold = card
	if Hold == Highest:
		accum += 1

print(accum/num_reps)


@@ -347,16 +347,68 @@
 = card%0D%0A
+%09%09# The thresholds are for cards numbered 1 to 100%0D%0A
 %09%09if Hol
@@ -444,16 +444,18 @@
 ds%5Bdeal%5D
+-1
 :%0D%0A%09%09%09Ho
@@ -503,16 +503,16 @@
 += 1%0D%0A%0D%0A
+
 print(ac
@@ -526,10 +526,8 @@
 _reps)%0D%0A
-%0D%0A

Update PickACard538.py