This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| javascript:(function(){ | |
| var num = 1; | |
| var els = document.getElementsByTagName('span'); | |
| for(var i=0; i<els.length; i++) { | |
| var prop = els[i].getAttribute('itemprop'); | |
| if(prop === "children") { | |
| var numElem = document.createTextNode("" + num + ". "); | |
| els[i].insertBefore(numElem, els[i].firstChild); | |
| var br = document.createElement("br"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| javascript:(function(){ | |
| var re_year = /\/(\d{4})\//; | |
| var yyyy = re_year.exec(document.location) || {}; | |
| var re_lang = /\/(eng|fra)\//; | |
| var lang = re_lang.exec(document.location) || {}; | |
| if (lang[1] === "fra") { | |
| document.location = document.location.replace("fra/recensements", "eng/census"); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "name": "flare", | |
| "children": [ | |
| { | |
| "name": "analytics", | |
| "children": [ | |
| { | |
| "name": "cluster", | |
| "children": [ | |
| {"name": "AgglomerativeCluster", "size": 3938}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name | value | |
|---|---|---|
| Locke | 4 | |
| Reyes | 8 | |
| Ford | 15 | |
| Jarrah | 16 | |
| Shephard | 23 | |
| Kwon | 42 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Context example | |
| // From https://github.com/garyburd/go-oauth/blob/master/examples/appengine/app.go | |
| package main | |
| import ( | |
| "fmt" | |
| "log" | |
| "net/http" | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "encoding/binary" | |
| "io" | |
| "log" | |
| "os" | |
| ) | |
| func write8(w io.Writer, b byte) error { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html> | |
| <head> | |
| <script src="calculate.js"> </script> | |
| <script> | |
| function convert(form) { | |
| var v = document.getElementById("zinput").value; | |
| var algo = document.getElementById("zalgo").value; | |
| document.getElementById("zoutput").value = eval(algo)(v); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ==> main.go <== | |
| package main | |
| /* | |
| #cgo LDFLAGS: -L${SRCDIR} mylib.a -lm | |
| #include <math.h> | |
| #include "mylib.h" | |
| int mysub(int n, int m) { return n-m; } | |
| */ | |
| import "C" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # var for session name (to avoid repeated occurences) | |
| sn=$RANDOM | |
| # Start the session and window 0 in $HOME | |
| # This will also be the default cwd for new windows created | |
| cd $HOME | |
| tmux new-session -s "$sn" -n $HOME -d |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import "fmt" | |
| import "sort" | |
| type Organ struct { | |
| Name string | |
| Weight Grams | |
| } |