Skip to content

Instantly share code, notes, and snippets.

success = 0
1000000.times {success += [0,1,2,3,4].zip([0,1,2,3,4].shuffle).select{|a,b| a==b}.size}
puts success.to_f/1000000
(defn fib [n]
(cond
(= 0 n) 1
(= 1 n) 2
:else (+ (fib (- n 2)) (fib (- n 1)))
)
)
(def fibmemo (memoize fib))
minute = (
mounts % (
24 * 60 * 60
)
) %
(
60 * 60
) / 60;
#include <thread>
int main (int argc, char const *argv[])
{
std::thread([](){});
return 0;
}
--- Portfile 2014-05-19 10:15:44.000000000 +0200
+++ Portfile.exr 2014-05-19 10:13:51.000000000 +0200
@@ -157,6 +157,13 @@
configure.args-replace --without-wmf --with-wmf
}
+variant exr description {Include support for EXR} {
+ depends_lib-append port:openexr \
+ port:ilmbase
+ configure.args-replace --disable-hdri --enable-hdri
def to_s
def to_s
"foo"
end
end
#!/usr/bin/env ruby
require 'pp'
require 'spotify'
require 'io/console'
USERNAME='tliff'
PLAYLIST='spotify:user:1121758979:playlist:1ohNJvub3eoB86tKumCC7U'
CONFIG = Spotify::SessionConfig.new({
api_version: Spotify::API_VERSION.to_i,
application_key: File.binread(File.expand_path("~/.spotify/spotify_appkey.key")),
▬▬▬▬▬▬▬▬▬ஜ۩۞۩ஜ▬▬▬▬▬▬▬▬▬▬▬▬▬
DAMN THIS NEW SPAM IS FANCY
▬▬▬▬▬▬▬▬▬ஜ۩۞۩ஜ▬▬▬▬▬▬▬▬▬▬▬▬
### Keybase proof
I hereby claim:
* I am tliff on github.
* I am tliff (https://keybase.io/tliff) on keybase.
* I have a public key whose fingerprint is EB1C BD17 E88A D86B 6692 9B91 9EF6 EC5C B14C EEB7
To claim this, I am signing this object:
Data:
etcdctl mkdir /vhosts
etcdctl mkdir /vhosts/foo
etcdctl mkdir /vhosts/foo/backends
etcdctl mkdir /vhosts/foo/hostnames
etcdctl set /vhosts/foo/backends/mybackend "192.168.0.1:8001"
etcdctl set /vhosts/foo/backends/myotherbackend "192.168.1.1:8001"
etcdctl set /vhosts/foo/hostnames/example "example.com"