Jeremy W. Sherman. January 2013.
OKR = Objectives & Key Results
- 3-5 objectives, or high-level, measurable goals
- 2-3 key results per objective, plus one "stretch" result.
- Should not be able to achieve ALL goals/results; you need to stretch yourself.
| import Euterpea.Music.Note.Music | |
| import Euterpea.IO.MIDI.ToMidi | |
| -- Writes |test.mid| in the current directory. | |
| main = test chord | |
| where chord = foldl1 (:=:) $ map (note 1.0) pitches | |
| pitches = [(Fs, o), (As, o), (Cs, o + 1), (Fs, o + 1)] | |
| o = 6::Int |
Jeremy W. Sherman. January 2013.
OKR = Objectives & Key Results
| //cc -Weverything -fobjc-arc -framework Foundation bitmask.m -o bitmask | |
| /** @file bitmask.m | |
| * @author Jeremy W. Sherman (@jeremy-w on Github) | |
| * @license ISC (http://opensource.org/licenses/isc-license.txt) | |
| * | |
| * Provides an example where assignment of the result of a naive bitmask check | |
| * to BOOL fails. | |
| * | |
| * Demonstrates 2 ways to avoid this issue. | |
| * |
| import Cocoa | |
| var input = "This is a test" | |
| var expected = "Guvf vf n grfg" | |
| /// Advances `i` by `by` through `string`, wrapping to start on hitting | |
| /// end. | |
| /// NOTE: `by` must be non-negative. | |
| func wrappingAdvance(string: String, i: String.Index, by: Int) | |
| -> String.Index { |
I hereby claim:
To claim this, I am signing this object:
| set-option -g prefix C-e | |
| unbind-key C-e | |
| bind-key C-e send-prefix | |
| set-window-option -g mode-keys vi | |
| # Fix weirdness with OS X bootstrap namespaces and daemon. | |
| # See https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard for details. | |
| set-option -g default-command "reattach-to-user-namespace -l zsh" |
| #import <Foundation/Foundation.h> | |
| @interface RSLRandomValueObject : NSObject<NSCopying, NSCoding> | |
| /* The @property bits are the only code I wrote. */ | |
| @property(copy) NSString *name; | |
| @property NSNumber *someNumber; | |
| @property BOOL supYo; | |
| /* Everything else in here and the implementation file | |
| * was generate by AppCode, either by the New File |
| import Data.Vect | |
| import Data.Fin | |
| -- Start by representing our universe as a product type. | |
| data Ty = TyInt | TyBool | TyFun Ty Ty | |
| interpret : Ty -> Type | |
| interpret TyInt = Int | |
| interpret TyBool = Bool | |
| interpret (TyFun A T) = interpret A -> interpret T |
| /* | |
| * Compile with: | |
| * rustc -Z unstable-options --pretty expanded pipe.rs | |
| */ | |
| /* @file pipe.rs | |
| * @author Jeremy W. Sherman (GitHub: @jeremy-w) | |
| * @license ISC | |
| * | |
| * Implements and demonstrates use of the "pipe" (aka "thread-first") macro. | |
| */ |
| // clang -framework Foundation dispatch_after_example.m -o dispatch_after_example | |
| // Compiling with gcc requires separating declaration of b from assignment, | |
| // but you can omit the -framework flag for GCC. | |
| /* @author Jeremy W. Sherman | |
| * @date 2011-06-03 | |
| * | |
| * Demonstrates use of a recursive block to set up a repeating action | |
| * using `dispatch_after()`. | |
| * Assumes 10.6+ or iOS with GCD and blocks (whichever version that was). | |
| */ |