I hereby claim:
- I am cimi on github.
- I am cimi (https://keybase.io/cimi) on keybase.
- I have a public key ASCCW9Z9WSeaRLZjVCHFSp2mZFScvMUuCBIuLK6YnSSI0Qo
To claim this, I am signing this object:
from itertools import groupby | |
from threading import Thread | |
from random import randint | |
from time import sleep | |
# see http://stackoverflow.com/questions/29291270/threading-in-python-processing-multiple-large-files-concurrently | |
for key, partition in groupby(range(1, 50), lambda k: k//10): | |
threads = [] | |
for idx in list(partition): | |
thread_name = 'thread-%d' % idx |
import urllib | |
import urllib2 | |
import json | |
import pprint | |
import codecs | |
import sqlite3 | |
import sys | |
import logging | |
import time |
define([], function () { | |
var helpers; | |
var Expandable = new Class; | |
Expandable.include({ | |
init : function (element) { | |
this.el = element; | |
this.parentList = helpers.getParentList(this.el); | |
this.menu = helpers.getMenu(this.el); | |
this.exclusive = true; |
<script type="text/javascript" src="http://www.google.com/jsapi"></script> | |
<script type="text/javascript"> | |
google.load('visualization', '1', {packages: ['corechart']}); | |
</script> | |
<script type="text/javascript"> | |
function drawVisualization() { | |
// Create and populate the data table. | |
var data = new google.visualization.DataTable(); | |
var raw_data = [ |
// intialization section | |
grammar CSS21; | |
options | |
{ | |
backtrack=true; | |
memoize=true; | |
superClass=DiguaParser; | |
} |
<!DOCTYPE html> | |
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]--> | |
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]--> | |
<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]--> | |
<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]--> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | |
<title></title> | |
<meta name="description" content=""> |
#!/bin/bash | |
if [ $# -ne 2 ]; then | |
echo "The script must take two arguments: namenode internal hostname and current machine internal hostname." | |
exit 0 | |
fi | |
# JAVA_HOME is not set by default | |
sudo sh -c "echo 'export JAVA_HOME=/usr/lib/jvm/java-6-openjdk' >> /etc/profile" | |
sudo ln -s /usr/lib/jvm/java-6-openjdk /usr/lib/jvm/java-openjdk # needed because bigtop-utils do not recognize the prev path | |
source /etc/profile |
import java.util | |
import scala.collection.mutable.ListBuffer | |
object PrimeFactorCalculator { | |
def prime(number: Integer):Boolean = { | |
if (number < 2) return false | |
if (number == 2) return true | |
for (i <- 3 to Math.sqrt(number.toDouble).toInt by 2 if (number % i == 0)) | |
return false | |
true |
require 'formula' | |
class ScalaDocs < Formula | |
homepage 'http://www.scala-lang.org/' | |
url 'http://www.scala-lang.org/files/archive/scala-docs-2.9.3.zip' | |
sha1 '633a31ca2eb87ce5b31b4f963bdfd1d4157282ad' | |
end | |
class Scala < Formula | |
homepage 'http://www.scala-lang.org/' |
I hereby claim:
To claim this, I am signing this object: