After a week of hard work, I kind of perfected the code. Enter your opinion in the comments section. It is pretty much normal blackjack except it does not have kings, queens, jacks or aces.(Still working on that part) but everything else is still normal...
Nice work. Here's a few lines of code to help with adding in the face cards-
Create a list:
cards = [2,3,4,5,6,7,8,9,10,'J','Q','K','A']*4 #this will give you 1 deck! add as many decks as you like.
Use random.sample to select the draw:
hand = random.sample(cards,2)
Decrement the deck by the cards you just drew:
for i in range(hand): #Do this for all drawn cards
Sum your hand:
for i in range(hand): if hand[i] == int: total += hand[i] elif hand[i] == 'A': # This gives the option to use Ace as either 1 or 11. if total + 11 > 21: total += 1 else: total += 11 else: total += 10
You can probably put together the rest of it. Good luck!