Skip to content

Instantly share code, notes, and snippets.

View willf's full-sized avatar
✒️
pondering

Will Fitzgerald willf

✒️
pondering
View GitHub Profile
@willf
willf / gschsc_2016.m3u
Created December 19, 2016 20:53
Georgia State Christian Harmony Convention 2016
http://shapenote.com/recordings/gschsc/2016/sat/session1/01-67T-notes.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/01-67T-words.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/02-359.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/03-319.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/04-61T.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/05-310.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/06-493.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/07-4.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/08-316.mp3
http://shapenote.com/recordings/gschsc/2016/sat/session1/09-543-notes.mp3
@willf
willf / stats.rb
Created November 14, 2016 20:54
Basic descriptive statistics using Ruby
# The _percentile_sorted function is adapted from similar code
# released under the Academic Free License, 3.0, written by
# Derrick Pallas, which used to be available at http://derrick.pallas.us/ruby-stats/
# it fixes a bug that can occur if the list of numbers is small.
# Other code more or less from my [first ever gist](https://gist.github.com/willf/187846)
def _percentile_sorted(p, ns)
r = p / 100.00 * (ns.size + 1)
i, fr = r.divmod(1)

Practice Resurrection

Luke 20:27-40
Will Fitzgerald
Kalamazoo Mennonite Fellowship
November 6, 2016

Some Sadducees, those who say there is no resurrection, came to him and asked him a question, "Teacher, Moses wrote for us that if a man's brother dies, leaving a wife but no children, the man shall marry the widow and raise up children for his brother. Now there were seven brothers; the first married, and died childless; then the second and the third married her, and so in the same way all seven died childless. Finally the woman also died. In the resurrection, therefore, whose wife will the woman be? For the seven had married her."

Jesus said to them, "Those who belong to this age marry and are given in marriage; but those who are considered worthy of a place in that age and in the resurrection from the dead neither marry nor are given in marriage. Indeed they cannot die anymore, because they are like angels and are children of God, being children of the resurrection.

The first number is the *base*, The first list is the list of prime rotations in that base, and the third are those rotations in base 10.
For example, in base 4, the numbers {113, 131, 311} (written in base 4) are all prime rotations, representing the prime numbers
{23, 29, 53} (written in base 10).
This is the complete list created from the first 2 million primes.
2 [11] [3]
2 [111] [7]
2 [11111] [31]
2 [1111111] [127]
@willf
willf / gist:32d72322353f17650ca7
Created December 1, 2015 00:04
ia archive social media messages
SOCIAL MEDIA MESSAGES
MESSAGE 1: KEEP INTERNET ARCHIVE FREE AND AD-FREE
TWITTER:
On #GivingTuesday help keep @InternetArchive free & ad-free forever! Your gift matched 2-1. https://archive.org/donate
FACEBOOK:
Tomorrow is #GivingTuesday. By supporting @InternetArchive you are putting knowledge in the hands of millions of people. Please help keep us free and ad-free forever! If you find us useful, please give what you can today. https://archive.org/donate
@willf
willf / example_flight.html
Last active October 30, 2015 21:09
Example HTML file with basic flight information for funnel analysis
<html>
<head>
<title>Simple funnel example, with three exit points</title>
<script src="http://archive.org/includes/jquery-1.10.2.min.js" type="text/javascript"></script>
<script src="http://www-will.archive.org/includes/analytics.js?v=20fd7fa_854659" type="text/javascript"></script>
</head>
<!-- the data-ec="my-app" means we'll get context counts for participate. data-app="my-app" sets limits (esp for the data-convert
items) on the events to capture.
on load, this will fire an event with {app:"myapp", ec: "myapp", t:"event", ea: "participate"}
-->
"@0xabad1dea I love the term \"Cutie Twitter\""
"@AccuRayno I love the term \"not as brutal\". I wonder what color it would be if the forecast was \"brutal\"?"
"@Ashton5SOS @Smallzy I love the word wallop!!"
"@CL_Hellisen @MindTheCurvesZA gorgeous! i love the expression, the pose!"
"@DannyNoriega danny i have like a major problem...i hate the word fag and my neighbor calls me\" gay spic fag boy\" what do i do? ps. i love u"
"@Gwenelope love the word Luddite. Almost as much as I love the words palimpsest and velvet #randomtweet"
"@JMamuds I love the term “organic mass”"
"@JamesTharpy24 I love the term meddler in the middle for TP. It more accurately described what we really do in our classroom."
"@Mikah_Clark Hello. Nerd. Also, I love the word abysmal and have been wanting to use it in a convo for like three days now. Deal."
"@NinBendo1 I hate the term, Christian. I am a follower of Christ. And He says to love EVERYONE. So, that is how I choose to live."
@willf
willf / gist:5f36c2cfb8512acabb24
Created June 22, 2015 13:15
Simple elastic search calls
from elasticsearch import Elasticsearch
es = Elasticsearch()
es.create(index="test", doc_type="articles", body={"content": "One more fox"})
res = es.search(index="test", doc_type="articles", body={"query": {"match": {"content": "fox"}}})
print("%d documents found" % res['hits']['total'])
for doc in res['hits']['hits']:
print("%s) %s" % (doc['_id'], doc['_source']['content']))
package org.entish.montecarlo
import scala.util.Random
import System.{ currentTimeMillis  _time }
import com.nicta.rng._, scalaz._, Scalaz._

object Main extends App {

  def profile[R](code:  R, t: Long = _time, msg: String = "Profile") = (msg, code, _time - t)
@willf
willf / student.scala
Created June 25, 2014 15:30
Simple Scala Student class
case class Student (fn: String, ln: String) {
def name() = s"$fn $ln"
def greet() = s"Hello, $name"
}
val s = Student("John", "Doe")
val l = List(s,s,s)
val res = l.map{_.name.length}.sum