Skip to content

Instantly share code, notes, and snippets.

View g-w1's full-sized avatar
📔
Learning!

Jacob G-W g-w1

📔
Learning!
View GitHub Profile
@g-w1
g-w1 / war.py
Last active February 9, 2020 03:26
a program that when given 2 decks of 26 for the card game war can return the output
import random
import time
def decksplit():
deck = list(range(13))*4
random.shuffle(deck)
p1 = deck[:26]
p2 = deck[26:]
return (p1,p2)
def printb(p1,p2, time, war = False):
print(p1)