Test JavaScript methods against each other accurate to 5 microseconds (five thousandths of a millisecond).
time = fn=>{let t=()=>performance.now(),s=t();fn();return t()-s}
time(() => document.querySelectorAll('span'))
// 0.18499999959021807
macro def { | |
rule { | |
$name:ident ( $($params:ident : $type:ident) (,) ...) $body | |
} => { | |
// just throwing away the type annotation. The semantics of type | |
// annotations left as an exercise to the reader :) | |
function $name ($params (,) ...) $body | |
} | |
} | |
Test JavaScript methods against each other accurate to 5 microseconds (five thousandths of a millisecond).
time = fn=>{let t=()=>performance.now(),s=t();fn();return t()-s}
time(() => document.querySelectorAll('span'))
// 0.18499999959021807
Dear non-executive team members,
All of my options have vested, and I haven’t been offered any new ones so my earning potential here is no longer all that great. Worse, as we’ve operated and developed better understandings of the problems we face it seems less likely than ever that we’ll achieve the vision we set out to achieve. Finally, the blackout periods are having a real negative effect on my ability to diversify my wealth and avoid the high risk of this company’s success chances. Therefore I’m leaving on a “high note” while we can still plausibly call this endeavor a success, and after I’ve left will convert all my equity in this venture into other forms of wealth while not having to report it
In 2015, I started diving deeper into GNU Emacs because I saw its potential as an assistive technology. Not only as a way of providing better access to books and code for my students and clients, many of whom are blind, but also as a tool for creating more accessible content. Regular expressions and modes like Org, Markdown, and AucTex are extremely useful in the production of alternate formats.
Although I had used Emacs as a vanilla text editor off and on since the 90's, I didn't learn anything about the underlying Emacs Lisp (elisp) programming language until the end of 2015, when I got a hardcopy Emacs manual, quit my day job, and grew t
// fun.cpp | |
extern "C" | |
{ | |
#include <lua.h> | |
#include <lauxlib.h> | |
#include <lualib.h> | |
} | |
#include <iostream> |
import nltk | |
# interactive download | |
# nltk.download() | |
nltk.download('punkt') | |
extra_abbreviations = [ | |
"ps", | |
"inc", | |
"corp", |
std::set phoenix;
phoenix.key_comp();
; The Expression Problem and my sources: | |
; http://stackoverflow.com/questions/3596366/what-is-the-expression-problem | |
; http://blog.ontoillogical.com/blog/2014/10/18/solving-the-expression-problem-in-clojure/ | |
; http://eli.thegreenplace.net/2016/the-expression-problem-and-its-solutions/ | |
; http://www.ibm.com/developerworks/library/j-clojure-protocols/ | |
; To begin demonstrating the problem, we first need some | |
; "legacy code" with datastructures and functionality: |
source "https://rubygems.org" | |
gem 'eventmachine' | |
gem 'sinatra' | |
gem 'yajl-ruby', require: 'yajl' | |
gem 'thin' | |
gem 'em-websocket' |