Skip to content

Instantly share code, notes, and snippets.

View ujihisa's full-sized avatar

ujihisa ujihisa

View GitHub Profile
require 'uri'
require 'rubygems'
require 'curb'
require 'json'
require 'rubytter'
module Lingrvim
class << self
AT = ['', '']
OA = ['', '']
import qualified Text.Parsec as P
main = do
print $ ", hello, world,!" `split` ", "
t `split` b = case P.parse (split' (P.string b)) "split" t of Right x -> x
split' b = P.anyChar `P.manyTill` (P.eof P.<|> (P.try b >> return ())) `P.manyTill` P.eof
" Knuth Subtractive Random Number Generator
let s:knuth_random = { 'index': 0, 'state': repeat([0], 56) }
function! s:knuth_random.seed(seed) dict
let l:seed = 161803398 - (a:seed < 0 ? -a:seed : a:seed)
let self.state[55] = l:seed
let [l:i, l:j, l:k] = [0, 0, 1]
for l:i in range(1, 54)
let l:j = (21 * l:i) % 55
@ujihisa
ujihisa / Rakefile
Created July 11, 2009 06:11 — forked from cho45/Rakefile
require "rubygems"
require "rake"
require "pathname"
require "rexml/document"
manifest = REXML::Document.new(File.read("AndroidManifest.xml"))
PACKAGE = manifest.elements["/manifest/@package"].value
NAME = manifest.elements["/manifest/application/activity/@android:name"].value