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
/** | |
1. Install the Stylish(https://chrome.google.com/webstore/detail/stylish/fjnbnpbmkenffdnngjfgmeleoegfcffe?hl=en) extension for Chrome. | |
2. Open up extension options and paste the CSS mentioned below. | |
3. Specify the "URLs on the domain" to be `github.com`. | |
4. Add a title and save. | |
*/ | |
.dashboard-sidebar { | |
float: right; | |
padding-right: 10px; |
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
<?php | |
class ColorCLI { | |
static $foreground_colors = array( | |
'bold' => '1', 'dim' => '2', | |
'black' => '0;30', 'dark_gray' => '1;30', | |
'blue' => '0;34', 'light_blue' => '1;34', | |
'green' => '0;32', 'light_green' => '1;32', | |
'cyan' => '0;36', 'light_cyan' => '1;36', |
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
# LZ77 Encoding | |
# | |
# Simple implementation of Lempel-Ziv 77 (a.k.a. "Sliding Window") coding | |
# as described in Section 13.4 of Cover & Thomas' "Information Theory". | |
# | |
# USAGE: python encode.py INPUT_STREAM | |
# | |
# EXAMPLE (from lectures): | |
# $ python encode.py abbababbababbab | |
# (0,a) |
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
#!/usr/bin/php | |
<?php | |
if (! isset($argv[1])) { | |
fputs(STDERR, "Please provide a URL to crawl\n"); | |
die(1); | |
} | |
if (! isset($argv[2])) { | |
fputs(STDERR, "Please provide an output filename\n"); |
NewerOlder