Skip to content

Instantly share code, notes, and snippets.

import random
birthday = 0
birthdays = []
counter = 0
simulations = 100000
for i in range (simulations):
print("type x to quit")
b = input("up to what number: ")
while b != "x":
li = []#list that stores the numbers produced
List = []#list that contains all lists
for i in range(2,int(b)):
li.append(i)
while i != 1:
if i % 2 == 0: #even
i = i/2
import socket
s = socket.socket()
host = '127.0.0.1'
port = 50004
s.bind((host, port))
s.listen(5)
conn = None
word = input("Hangman word:" )
while True:
if conn is None:
def drawing(tries):
if tries == 6:
print(" _______")
print("| |")
print("|")
print("|")
print("|")
print("|")
print("|")
elif tries == 5:
def drawing(tries): #this is the function that draws gallows depending on how many tries the player has left
if tries == 6:
print(" _______")
print("| |")
print("|")
print("|")
print("|")
print("|")
print("|")
elif tries == 5: