Skip to content

Instantly share code, notes, and snippets.

@devinus
Created August 30, 2012 21:42
Show Gist options
  • Save devinus/3541920 to your computer and use it in GitHub Desktop.
Save devinus/3541920 to your computer and use it in GitHub Desktop.
// [name, before, after]
var injections = [['b', 'c', null], ['a','b', null], ['d', null, 'c'], ['c', null, null], ['e', null, 'd']];
// Sort injections such that:
// 1) a is before b
// 2) b is before c
// 3) d is after c
// 4) e is after d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment