This file contains 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
abbrev ff :!open -a Firefox.app %:p<cr> | |
abbrev chrome :!open -a Google\ Chrome.app %:p<cr> | |
abbrev sf :!open -a Safari.app %:p<cr> |
This file contains 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
/* | |
Ratings Stars | |
(with as little code as possible) | |
*/ | |
.rating { | |
unicode-bidi: bidi-override; | |
direction: rtl; | |
text-align: center; | |
} | |
.rating > span { |
This file contains 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
" colorschemes {{{ | |
NeoBundle 'biskark/vim-ultimate-colorscheme-utility' | |
NeoBundle 'flazz/vim-colorschemes' | |
NeoBundle 'altercation/vim-colors-solarized' | |
NeoBundle 'Lokaltog/vim-distinguished' | |
NeoBundle 'sjl/badwolf' | |
NeoBundle 'chriskempson/tomorrow-theme', { 'rtp' : 'vim/' } | |
NeoBundle 'w0ng/vim-hybrid' | |
NeoBundle 'zaiste/Atom' | |
NeoBundle 'tomasr/molokai' |
This file contains 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 inOrnagai = function(word) { | |
var result = []; | |
makeRequest(word, function(status, response) { | |
var words = JSON.parse(response); | |
result = words.filter(function(value) { | |
return value.word.toLowerCase() === word.toLowerCase(); | |
}); | |
console.log("Inside: ", result); | |
}); | |
console.log("Outside: ", result); |
This file contains 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/sh | |
# Some things taken from here | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# Set the colours you can use | |
black='\033[0;30m' | |
white='\033[0;37m' | |
red='\033[0;31m' | |
green='\033[0;32m' |
This file contains 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
let (<>) a b = | |
let rec timesPrime a b acc = match b with | |
| 0 -> acc | |
| _ -> timesPrime a (pred b) (acc+a) | |
in timesPrime a b 0 | |
;; | |
let rec pow x = function | |
| 0 -> 1 | |
| n when n mod 2 = 0 -> |
This file contains 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
#include <iostream> | |
using namespace std; | |
int main(void) { | |
int i = 37; | |
float f = *(float*)&i; | |
cout << f << endl; | |
return 0; | |
} |
This file contains 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
#include <iostream> | |
using namespace std; | |
int main(void) { | |
int i = 37; | |
float f = *(float*)&i; | |
cout << f << endl; | |
return 0; | |
} |
This file contains 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
import java.util.regex.*; | |
public class RegexTest { | |
public static void main(String[] args) { | |
String burmeseNumbers = "αααααα αααα"; | |
String engRegex = "0|1|2|3|4|5|6|7|8|9"; | |
String burmeseRegex = "α|α|α|α|α|α |α|α|α|α"; |
This file contains 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
-- 1 | |
CREATE TABLE book ( | |
title VARCHAR(256) NOT NULL, | |
format CHAR(9) NOT NULL, | |
pages INT, | |
authors VARCHAR(256), | |
publisher VARCHAR(256), | |
year DATE, | |
edition INT, | |
ISBN10 CHAR(10) NOT NULL UNIQUE, |
OlderNewer