INSERT 0 78500
0.14s user 0.03s system 6% cpu 2.786 total
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
# This script converts an exported mind map from MindNode | |
# to JSON, for instance for using with D3.js (http://d3js.org). | |
# | |
# Example: `./mindmap.rb > structure.json` | |
$LOAD_PATH.unshift '.' | |
require 'json' | |
file = File.open('./mind-map.txt') | |
class String |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>NSTableView Columns bmtable</key> | |
<array> | |
<data> | |
BAtzdHJlYW10eXBlZIHoA4QBQISEhAhOU1N0cmluZwGEhAhOU09iamVjdACF | |
hAErBWltYWdlhg== | |
</data> |
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 | |
# This script will install the Kiosk-browser "Plainview", configure it | |
# for the Ma-Expo and add it to the startup items. | |
APPLICATION_NAME="Plainview.app" | |
APPLICATION_FOLDER=~/Applications/ | |
TMP_FOLDER="/tmp/expo$(date +%s)" | |
mkdir -p $TMP_FOLDER |
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 | |
git_log_json() { | |
echo '{'; | |
git log --pretty=format:' "%h": {%n "commit": "%H",%n "author": "%an <%ae>",%n "date": "%ad",%n "message": "%s"%n },' | cut -d ',' -f 1; | |
echo '}'; | |
} |
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
-- Splits up a list in groups of n items. For example: | |
-- groupsOf 5 ['a'..'z'] == ["abcde","fghij","klmno","pqrst","uvwxy","z"] | |
groupsOf :: Int -> [a] -> [[a]] | |
groupsOf n [] = [] | |
groupsOf n list = | |
let group = take n list | |
rest = drop n list | |
in group:(groupsOf n rest) |
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
public class Bar extends Foo { | |
public static String name = "Bar!"; | |
} |
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
function readBookFromRow(row) { | |
var raw_info = row.children('.col-info').attr('onmouseover'); | |
raw_info = raw_info.replace("tooltip.show('", ''); | |
var book = { | |
title: row.children('.col-artikel').attr('title'), | |
price: row.children('.col-kortingprijs').attr('title'), | |
mandatory: row.children('.col-aanbevolen').attr('title'), | |
raw_info: raw_info | |
}; |
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
const print = console.log.bind(this); // Utility print function | |
// Some unsorted data | |
const numbers = [3, 4, 2, 5, 1, 6, 7, 4, 8, 2, 1, 9]; | |
const word = 'quicksort op hogeschool leiden'; | |
// Sorting example | |
const sorted_word = quicksort(word.split('')); | |
const sorted_numbers = quicksort(numbers); |
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
var Brainfuck = function(code) { | |
var debug = false; | |
var memory = []; | |
var ptr = 0; | |
var output = ''; | |
for(var i = 0; i <= code.length; i++) { | |
var c = code[i]; | |
switch(c) { | |
case '>': // Increment pointer |