Skip to content

Instantly share code, notes, and snippets.

View snoble's full-sized avatar

Steven Klaiber-Noble snoble

View GitHub Profile
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>moments -- Sage</title>
<link type="text/css" rel="stylesheet" href="/css/main.css" />
a = 2 if a.nil?
if b.nil?
b = 2
end
Git error: command `git clone 'git@github.com:Shopify/internal_app_engine.git' "/tmp/build_2i47vki223km9/vendor/bundle/ruby/1.9.1/cache/bundler/git/internal_app_engine-da5b2a5d7e7f3a2d844b755ffbb008127c69c1e2" --bare --no-hardlinks` in directory /tmp/build_2i47vki223km9 has failed.
!
! Failed to install gems via Bundler.
!
! Heroku push rejected, failed to compile Ruby/rails app
def foo(x); 99; end
a = foo (44) / 11
foo = 99999999
b = foo (44) / 11
puts "a: #{a} b: #{b}" #output of "a: 99 b: 9"
def significance(c_prediction, c_actual)
c_prediction - c_actual + (c_actual == 0 ? 0 : c_actual*(Math.log(c_actual) - Math.log(c_prediction)))
end
@snoble
snoble / keys.json
Last active January 1, 2016 19:39
Alice's keys. Passphrase is "alice has a bad passphrase".
{
"publickey":"b61aad410f6d6f81071e8f8d52cb100a98be52ee619efd49268acfa1bf7a48f0021bd4e6dda368912b07efc37a7fbad9a0d25154191c4ef5cb31a314e18d1e31f851e0c1c93fa09b035cc57879ec897598920e14387110ffe6f401e635b19dc8fde0355cfe63d8ff260d478659816eab9f093a0384b9a65daf24db5105cd3b29",
"ed":"bf2a7accb1bffb276b45dcf03d213b7ea087cd9fd66a49a96ac6b57f74d985f381f9abf1bafc8db5d25d27cac9ab268997c498832f7fad194e31776b6a4c208593adc1d568a3b65ea64dbfdaca57c49cb738acf90e60cd536090ef7571f687284294948343f1af6551d563b334ce60011643c77ed5a2a0dad834916d8a298e14c421e13854fc2916195814168fef9ebf",
"erk":"b2b9133d89b67a5697b8d052e4782722463f88233d3b124a16a22b99124cbc41387047ffa3dde76aa60a2ef4a8c1223e953a6433e6279242f022ae7c05a07a6581103eecfabb4b0129697967d067a2807dd8b79fcfc0323ff75d8d6d240acf2108436cc82f844c0da78a3b8b0306f7e1a8945c710154fe29f43378603a89ac44",
"efk":"a221f7a4a34a7c5576168cec202b48a496e67269ebeb22dbf34cd74a6700333f50574e2ffc652f676d4b7aca06772df436c883d1e19c611e841288b842df3bace79b4a82633888a6d03b35cf62357e1ae28c792b45ff

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 / Simple Contour Plot.markdown
Created November 28, 2015 04:10
Simple Contour Plot
@snoble
snoble / boy_names.txt
Last active July 10, 2017 04:10
boy names that dropped in popularity
+-------------+---------------+---------------+------------------+------------------+
| Name | Old peak rate | Old peak year | Recent peak rate | Recent peak year |
+-------------+---------------+---------------+------------------+------------------+
| Herbert | 7.32e-03 | 1929 | 6.59e-04 | 1967 |
| Warren | 7.08e-03 | 1921 | 9.12e-04 | 1966 |
| Francis | 6.59e-03 | 1915 | 9.51e-04 | 1966 |
| Woodrow | 4.55e-03 | 1913 | 8.77e-05 | 1969 |
| Franklin | 5.41e-03 | 1933 | 7.29e-04 | 1966 |
| Alfred | 5.64e-03 | 1928 | 9.37e-04 | 1967 |
| Dewey | 9.09e-03 | 1898 | 1.32e-04 | 1966 |