Skip to content

Instantly share code, notes, and snippets.

View mattroseman's full-sized avatar

Matthew Roseman mattroseman

View GitHub Profile
@mattroseman
mattroseman / dgg-script.js
Last active February 23, 2023 19:07
DGG Scripts: A catchall Tampermonkey script for messing around with adding stuff to destiny.gg chat
// ==UserScript==
// @name DGG Scripts
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Random scripts modifying DGG and DGG chat
// @author Matthew Roseman
// @match *://*.destiny.gg/embed/chat*
// @icon https://www.google.com/s2/favicons?sz=64&domain=destiny.gg
// @grant none
// @run-at document-start
@mattroseman
mattroseman / .vimrc
Last active January 8, 2021 23:20
vim configuration
" General
syntax on
let mapleader = '-'
let python_highlight_all=1
set nocompatible
filetype off
set backspace=indent,eol,start
set encoding=utf-8
set nu
set fileformat=unix
@mattroseman
mattroseman / super_examples.py
Last active March 24, 2020 19:41
Example implementations of how Python's super() function works
class A:
def foo(self):
print('A foo method')
def bar(self):
print('A bar method')
class B(A):
def foo(self):
@mattroseman
mattroseman / radix.js
Created February 6, 2020 02:05
Radix Tree implementation in JavaScript
const util = require('util');
const setImmediatePromise = util.promisify(setImmediate);
class RadixNode {
constructor(edgeLabel, isWord=false) {
this.edgeLabel = edgeLabel;
this.children = {};
this.isWord = isWord;
}