Here is a description of `Finger Binary in Wikipedia`_.
Finger binary is a system for counting and displaying binary numbers on the
| import bisect | |
| class NFA(object): | |
| EPSILON = object() | |
| ANY = object() | |
| def __init__(self, start_state): | |
| self.transitions = {} | |
| self.final_states = set() | |
| self._start_state = start_state |
Here is a description of `Finger Binary in Wikipedia`_.
Finger binary is a system for counting and displaying binary numbers on the
| // ==UserScript== | |
| // @name UTM param stripper | |
| // @author Paul Irish | |
| // @namespace http://github.com/paulirish | |
| // @version 1.2 | |
| // @description Drop the UTM params from a URL when the page loads. | |
| // @extra Cuz you know they're all ugly n shit. | |
| // @include http*://* | |
| // ==/UserScript== |
| /* Compile with: g++ -Wall –Werror -o shell shell.c */ | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <ctype.h> | |
| #include <unistd.h> | |
| #include <sys/types.h> | |
| #include <sys/wait.h> |
| // ==UserScript== | |
| // @name RoboHash Your Twitters | |
| // @namespace rjp | |
| // @description Replace twitter avatars with RoboHash avatars | |
| // @include http://twitter.com/ | |
| // ==/UserScript== | |
| // linkifyContainer idea gratefully and wholly stolen from | |
| // http://arantius.com/misc/greasemonkey/linkify-plus.user.js# | |
| // with minor reformatting by me to make a nicer gist |
| def hexdump(src, length=16): | |
| FILTER = ''.join([(len(repr(chr(x))) == 3) and chr(x) or '.' for x in range(256)]) | |
| lines = [] | |
| for c in xrange(0, len(src), length): | |
| chars = src[c:c+length] | |
| hex = ' '.join(["%02x" % ord(x) for x in chars]) | |
| printable = ''.join(["%s" % ((ord(x) <= 127 and FILTER[ord(x)]) or '.') for x in chars]) | |
| lines.append("%04x %-*s %s\n" % (c, length*3, hex, printable)) | |
| return ''.join(lines) |
| ############## | |
| # Xft settings | |
| ############## | |
| Xft.dpi: 96 | |
| Xft.antialias: true | |
| Xft.rgba: rgb | |
| Xft.hinting: true | |
| Xft.hintstyle: hintslight |
| #!/usr/bin/env python | |
| import dpkt, pcap, socket | |
| from ipaddr import IPv4Address, IPv6Address | |
| import syslog | |
| class HTTPRequest(): | |
| def __init__(self, host, uri, ip = None, user_agent = None): | |
| self.uri = uri | |
| self.user_agent = user_agent | |
| self.host = host |
| import email, getpass, imaplib, os | |
| detach_dir = '.' # directory where to save attachments (default: current) | |
| user = raw_input("Enter your GMail username:") | |
| pwd = getpass.getpass("Enter your password: ") | |
| # connecting to the gmail imap server | |
| m = imaplib.IMAP4_SSL("imap.gmail.com") | |
| m.login(user,pwd) | |
| m.select("cs2043") # here you a can choose a mail box like INBOX instead |
| # http://stackoverflow.com/questions/748324/python-convert-those-tinyurl-bit-ly-tinyurl-ow-ly-to-full-urls | |
| ############# | |
| # urllib2 | |
| import urllib2 | |
| fp = urllib2.urlopen('http://bit.ly/rgCbf') | |
| fp.geturl() | |
| # ==> 'http://webdesignledger.com/freebies/the-best-social-media-icons-all-in-one-place' |