Skip to content

Instantly share code, notes, and snippets.

sudo sh -c "release=`lsb_release -c | cut -d':' -f2 | sed -e 's/^[ \t]*//g'` && grep $release-security /etc/apt/sources.list > /tmp/secsrc.list && apt-get -o Dir::Etc::sourcelist='/tmp/secsrc.list' -o Dir::Etc::sourceparts='-' update && apt-get --assume-no upgrade"

Keybase proof

I hereby claim:

  • I am phlipper on github.
  • I am phlipper (https://keybase.io/phlipper) on keybase.
  • I have a public key whose fingerprint is 18FE FBC6 C65E 4DA2 316E 56B3 876E 9949 2B9E B672

To claim this, I am signing this object:

@phlipper
phlipper / exercise1.rb
Created September 19, 2014 00:50
TECH 601-00 Warm-up Exercise - Thursday 2014-09-18
# 1. create a variable named 'a' with the value of 1 and display 'a'
# 2. create a variable named 'b' with the value of 2 and display 'b'
# 3. create a variable named 'c' with the value of 3 and display 'c'
# 4. create a variable named 'd' with the value of 10 and display 'd'
# 5. add 'a' and 'b' and display the result
# 6. add 'a' and 'd' and display the result
# 7. add 'a' and 'b' and 'c' and 'd' and display the result
# 8. multiply 'd' and 'b' and display the result
# 9. multiple 'd' by itself and display the result
# 10. divide 'd' by 'b' and display the result
@phlipper
phlipper / exercise2.rb
Created September 23, 2014 21:37
TECH 601-00 Warm-up Exercise - Tuesday 2014-09-23
# 1. assign the string "5" to a variable and display the value
# 2. assign the integer 5 to a variable and display the value
# 3. add the two variables by coercing the first value to an integer, assign
# that value to a variable, and display the value
# 4. add the two variables by coercing the second value to a string, assign
# that value to a variable, and display the value
@phlipper
phlipper / colors.rb
Created September 27, 2014 22:57
TECH 601-00 - Examples and Solutions
colors = ["purple", "yellow", "blue", "white", "red", "green", "orange"]
puts colors[4]
puts colors[40]
puts colors.index("green")
puts colors.index("foo")
colors2 = [
["tuesday", "purple"],
["saturday", "yellow"],
@phlipper
phlipper / Gemfile
Last active August 29, 2015 14:07
TECH 601-00 Course Database Project
source "https://rubygems.org"
gem "nokogiri"
@phlipper
phlipper / base62_benchmark.rb
Last active August 29, 2015 14:13
Base62 implementation benchmark
require "all_your_base"
require "benchmark/ips"
require "minitest/autorun"
require "securerandom"
BASE62_CHARS = [
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9",
"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o",
"p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "A", "B", "C", "D",
"E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S",
@phlipper
phlipper / population_database.json
Last active August 29, 2015 14:16
Database of Countries and Population Indicators
[{"id":"ABW","iso2Code":"AW","name":"Aruba","region":{"id":"LCN","value":"Latin America & Caribbean (all income levels)"},"adminregion":{"id":"","value":""},"incomeLevel":{"id":"NOC","value":"High income: nonOECD"},"lendingType":{"id":"LNX","value":"Not classified"},"capitalCity":"Oranjestad","longitude":"-70.0167","latitude":"12.5167","population":[{"indicator":{"id":"SP.POP.TOTL","value":"Population, total"},"data":[{"date":"2014","decimal":"1","value":null},{"date":"2013","decimal":"1","value":"102911"},{"date":"2012","decimal":"1","value":"102384"},{"date":"2011","decimal":"1","value":"101932"},{"date":"2010","decimal":"1","value":"101597"}]},{"indicator":{"id":"SP.RUR.TOTL.ZS","value":"Rural population (% of total population)"},"data":[{"date":"2014","decimal":"0","value":null},{"date":"2013","decimal":"0","value":"57.942"},{"date":"2012","decimal":"0","value":"57.636"},{"date":"2011","decimal":"0","value":"57.302"},{"date":"2010","decimal":"0","value":"56.941"}]},{"indicator":{"id":"SP.RUR.TOTL","value"
@phlipper
phlipper / README.md
Created March 5, 2015 23:42
Example README from Nitrous

Welcome to Nitrous.IO

Nitrous.IO enables you to develop web applications completely in the cloud. This development "box" helps you write software, collaborate real-time with friends, show off apps to teammates or clients, and deploy apps to production hosting sites like Heroku or Google App Engine.

Getting Started