Skip to content

Instantly share code, notes, and snippets.

@fenimore
fenimore / A Set Up and Clean Corpus
Last active August 29, 2015 14:19
DREaM Sentiment Analysis
import os
import nltk
import glob
import matplotlib.pyplot as plt
import re
from os import listdir
from bs4 import BeautifulSoup
from textblob import TextBlob
#this is the function to string xml tags from files
@fenimore
fenimore / liferea Solarized Style
Created May 10, 2015 13:10
Liferea Solarized STyle
/**
Liferea style for Molly
using the Solarized Color Palette found:
ethanschoonover.com/solarized
I think there are some redundancies in this,
and the titles don't show up so nice. (too dark)
*/
div.content img {
max-width:100%;
@fenimore
fenimore / post-install installs
Last active September 14, 2016 18:06
a list of applications for fleshing out a fresh install of linux
... install:
# arch
sudo pacman -S git emacs bpython vlc guake transmission-gtk firefox dstat gimp oh-my-zsh
zsh wpa_supplicant screen sudo
git emacs python3 bpython vlc guake
#develop
sudo apt-get install git filezilla ipython ipython-notebook pip
@fenimore
fenimore / app.py
Last active August 29, 2015 14:25
flask-photo-manager
import os
from flask import Flask, request, redirect, url_for, render_template, send_from_directory
from werkzeug import secure_filename
# initialization
app = Flask(__name__)
UPLOAD_FOLDER = os.path.join(app.root_path, 'uploads')
ALLOWED_EXTENSIONS = set(['txt','pdf','png','jpg'])
@fenimore
fenimore / .conkerorrc
Last active December 4, 2017 21:02
Dotfiles
user_pref("javascript.options.strict", false);
user_pref("javascript.options.showInConsole", false);
define_key(content_buffer_normal_keymap, "d", "follow-new-buffer");
let (home = get_home_directory()) {
home.append("home.html");
homepage = home.path;
}
@fenimore
fenimore / ttt.py
Last active May 24, 2016 19:31
tictactoe demonstration
#!/usr/bin/env python
"""Tic Tac Toe
A python module for playing tic tac toe.
The MIT License (MIT)
Copyright (c) 2016 Fenimore Love
TODO:
Add Color output
@fenimore
fenimore / linkedlist.py
Created September 30, 2016 21:18
Linked List in Python 3
"""
Implementation of Linked List in Python 3 with basic methods
"""
class Node(object):
"""Node is the basic object in a linked list"""
value = ""
reference = [] # Why is this an Empty node?
parent = []
def __init__(self, v):

Keybase proof

I hereby claim:

  • I am fenimore on github.
  • I am nevermore (https://keybase.io/nevermore) on keybase.
  • I have a public key whose fingerprint is 70D0 712D 01C7 0367 46DE 262A DE1B D2B1 80E8 4800

To claim this, I am signing this object:

@fenimore
fenimore / fizzbuzz.go
Created January 12, 2017 16:16
FizzBuzz iteratively and recursively https://play.golang.org/p/NAl_rTcCxe
// fizzbuzz see the goplayground for output
// https://play.golang.org/p/NAl_rTcCxe
package main
import (
"fmt"
)
// recursiveFizzBuzz returns a string
// of every FizzBuzz output from the original
@fenimore
fenimore / hash function for hash table
Created August 24, 2017 16:18
Hash Function for Hash Table
var TABLE_SIZE = 512
func hash(s string) int {
hash := 0
length := len(s)
prime := 233
for i := 0; i < length; i++ {
hash += prime^(length-i+1) * int(s[i])