This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
cat docword_as_id | sort -t',' -k1 | uniq | awk -F"," '{if (index($2," ")>0) print$0}' | wc -l --tathagatadg Tue 13 Sep 2011 04:15:20 PM CDT |
1. Change the perspective to Debug | |
2. Right click on the class containing main in Debug box | |
3. Select property. Copy the code |
#Stop tomcat started from Eclipse, helpful when it throws java.lang.OutOfMemoryError: PermGen space | |
kill -9 `ps aux | grep java | grep tomcat | cut -d' ' -f7` | |
#list all sizes of the directory | |
du -sh * |
String plaintext = "your text here"; | |
MessageDigest m = MessageDigest.getInstance("MD5"); | |
m.update(plaintext.getBytes()); | |
byte[] digest = m.digest(); | |
BigInteger bigInt = new BigInteger(1,digest); | |
String hashtext = bigInt.toString(16); | |
// Now we need to zero pad it if you actually want the full 32 chars. | |
while(hashtext.length() < 32 ){ | |
hashtext = "0"+hashtext; | |
} |
#if there is a -1 in a list | |
x = [1,1,1] | |
any(i for i in x if i==-1) | |
True | |
# if all elements of the list are equal | |
x = [1,1,1] | |
all(x[0] == i for i in x) | |
True |
min = float('inf') | |
for x in somelist: | |
if x<min: | |
min=x |
1. visually comment out block | |
- select section visually | |
- go to command mode | |
- s/^/# enter. comments | |
- s/#/ enter. uncomments | |
NERDTree |
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js" type="text/javascript" ></script> |