Skip to content

Instantly share code, notes, and snippets.

View dubpirate's full-sized avatar
🏠
whats good

William dubpirate

🏠
whats good
  • Calibrate Marketing
  • Auckland, New Zealand
View GitHub Profile
@dubpirate
dubpirate / the_menu.py
Last active February 13, 2020 03:42
I'm sure we've all heard the joke about "eating the rich" so here's the menu! It scrapes the Wikipedia page of richest Americans, then scrapes their wikipedia pages for their net worth, then saves it all as a csv. Please not this is NOT how I actually name variables, I just thought it was funny :). Something I whipped up for a job application at…
from bs4 import BeautifulSoup
import csv
import requests
url = "https://en.wikipedia.org/wiki/List_of_Americans_by_net_worth"
req = requests.get(url)
soup = BeautifulSoup(req.content, 'html5lib')
@dubpirate
dubpirate / main.py
Created April 11, 2019 02:07
MatrixFlipper created by dubpirate - https://repl.it/@dubpirate/MatrixFlipper
import numpy as np
lmin = -3 # (0 - (layers/2 round down))
lmax = 3 # layers/2 round down
# Creates a 4x4 Matrix where every object is a tuple: (x, y) <- Tuple
matrix = np.zeros((4, 4), dtype=tuple)
# Fill the matrix with the tuples corrosponding to the x, y, values.
for x in range(0, 4):
@dubpirate
dubpirate / index.html
Created December 3, 2018 00:07
platform created by dubpirate - https://repl.it/@dubpirate/platform
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>p5js Platform Mechanics</title>
<link href="style.css" rel="stylesheet" type="text/css" />
</head>