Follow the steps below to setup a local development environment:
Recommended to download latest XQuartz
Follow the steps below to setup a local development environment:
Recommended to download latest XQuartz
import javax.crypto.Cipher; | |
class Test { | |
public static void main(String[] args) { | |
try { | |
System.out.println("Hello World!"); | |
int maxKeyLen = Cipher.getMaxAllowedKeyLength("AES"); | |
System.out.println(maxKeyLen); | |
} catch (Exception e){ | |
System.out.println("Sad world :("); |
python gen_task_assignment_conf.py -m 10 -s 60 --hosts $hosts --ports $ports |
#coding=utf8 | |
read_ints = lambda: map(int, raw_input().split()) | |
#先假设没有正负号 | |
# 1 + (12 + 4) | |
# 提高, 有正负号怎么办呢? | |
#((1+2)*(-333+4)+1) * (-5) | |
# 1 * -5 |
http://stackoverflow.com/questions/11409518/how-to-remove-last-6-characters-of-every-line-in-vim |
#http://mapredit.blogspot.com/2013/05/get-all-extended-hive-tables-with.html | |
for file in $(hive -e "show table extended like \`*\`" | grep location: | awk 'BEGIN { FS = ":" };{printf("hdfs:%s:%s\n",$3,$4)}'); do hdfs dfs -du -h $file; done; |
#http://stackoverflow.com/questions/15105135/bash-capturing-output-of-awk-into-array | |
lists=("http://www.youtube.com/watch?v=tKTZoB2Vjuk" | |
"http://www.youtube.com/watch?v=EPYupizJYQI" | |
"http://www.youtube.com/watch?v=haycL41dAhg" | |
"http://www.youtube.com/watch?v=kWyoYtvJpe4" | |
"http://www.youtube.com/watch?v=uKZ8GBKmeDM" | |
"http://www.youtube.com/watch?v=Nn2KQmVF5Og" | |
"http://www.youtube.com/watch?v=IcteAbMC1Ok"); |
gsh --hosts-file=hosts |
import os | |
import imp | |
WORKDIR = os.path.dirname(os.path.abspath(__file__)) | |
path = lambda *a: os.path.join(WORKDIR, *a) | |
importer = lambda m, path: imp.load_module(m, *imp.find_module(m, [path])) | |
env LC_CTYPE=C tr -dc "a-zA-Z0-9-_\$\?" < /dev/urandom | head -c 10 |