Skip to content

Instantly share code, notes, and snippets.

View snoble's full-sized avatar

Steven Klaiber-Noble snoble

View GitHub Profile

Keybase proof

I hereby claim:

  • I am snoble on github.
  • I am snoble (https://keybase.io/snoble) on keybase.
  • I have a public key whose fingerprint is A3A1 908E 91E6 333C E66D 76AA 8947 AAD4 946C 55A3

To claim this, I am signing this object:

WITH input AS (SELECT MD5('some input string') AS input, 20 AS modulo),
mods AS (
SELECT
STRTOL(SUBSTRING(input,1,8),16) % modulo AS a,
STRTOL(SUBSTRING(input,9,8), 16) % modulo AS b,
STRTOL(SUBSTRING(input,17,8), 16) % modulo AS c,
STRTOL(SUBSTRING(input,25,8), 16) % modulo AS d,
POW(POW(16 % modulo, 4)::INT % modulo, 2)::INT % modulo AS offset_multiplier,
modulo
FROM input)
@snoble
snoble / gist:1848714
Created February 16, 2012 23:24
one more idea
create table internal.fedex_bad1 AS
select o1.order_id, o1.shipping_address_id, o1.created_at, o1.email
from orders o1
JOIN addresses a ON (o1.shipping_address_id = a.address_id)
JOIN internal.address_hashes ah ON (ah.address_id = a.address_id)
where
o1.financial_status = 'paid'
AND o1.created_at >= '2010-07-01'
AND o1.created_at <= '2011-07-01'
AND NOT EXISTS (
echo -e "\nbody {background-image: url('https://dl.dropbox.com/s/515ruct9cor67gj/sb.jpg') "'!'"important;}\n" >> ~/Library/Application\ Support/Google/Chrome/Default/User\ StyleSheets/Custom.css
echo -e "\nimg {-webkit-transform: scaleY(-1) "'!'"important;}\n" >> ~/Library/Application\ Support/Google/Chrome/Default/User\ StyleSheets/Custom.css
@snoble
snoble / index.html
Created August 10, 2012 02:05
Monotone Interpolation Bug
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
font: 10px sans-serif;
}
.axis path, .axis line {
fill: none;
@snoble
snoble / index.html
Created August 10, 2012 16:46
Cardinal Interpolation Bug
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
font: 10px sans-serif;
}
.axis path, .axis line {
fill: none;
@snoble
snoble / index.html
Created August 10, 2012 18:53
Monotonic Interpolation Bug
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
font: 10px sans-serif;
}
.axis path, .axis line {
fill: none;
@snoble
snoble / index.html
Created August 10, 2012 18:57
Cardinal interpolation fix
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
font: 10px sans-serif;
}
.axis path, .axis line {
fill: none;
@snoble
snoble / index.html
Created August 10, 2012 19:00
Monotonic Interpolation Fix
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
font: 10px sans-serif;
}
.axis path, .axis line {
fill: none;