A Pen by Lucien Gendrot on CodePen.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
import requests | |
import os | |
import argparse | |
from selenium import webdriver | |
from urllib.request import urlopen | |
from urllib.parse import urlparse | |
from PIL import ImageFile | |
from bs4 import BeautifulSoup |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class State: | |
def __init__(self, left_m=5, right_m=0, left_c=5, right_c=0, boat='left', parent=None, couples=5, boat_holds=3): | |
if parent == None: | |
assert left_m == left_c == couples, "Invalid root state lefts must equal couples" | |
self.left_m = left_m | |
self.right_m = right_m | |
self.left_c = left_c | |
self.right_c = right_c | |
self.boat = boat |