This file contains hidden or 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/bash | |
function f() { | |
local v=() | |
echo ${#v[@]} | |
} | |
f |
This file contains hidden or 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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains hidden or 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
package com.khotyn.java8; | |
import org.junit.Assert; | |
import org.junit.Test; | |
import org.junit.runner.RunWith; | |
import org.junit.runners.JUnit4; | |
/** | |
* 测试 Java 8 中的接口的 default 功能 | |
* |
This file contains hidden or 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
package com.khotyn.test; | |
import java.lang.instrument.Instrumentation; | |
public class AgentInstall { | |
public static void premain(String agentArgs, Instrumentation inst) { | |
InstrumentationHolder.setInstrumentation(inst); | |
} | |
} |
This file contains hidden or 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
package com.khotyn.test; | |
/** | |
* Created with IntelliJ IDEA. | |
* User: khotyn | |
* Date: 12-10-18 | |
* Time: 下午9:14 | |
* To change this template use File | Settings | File Templates. | |
*/ | |
public class CircularArray { |
This file contains hidden or 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
/** | |
* Conditional Expression Test. The result is | |
* | |
* <pre> | |
* 114.0 | |
* class java.lang.Double | |
* </pre> | |
* | |
* So why the result is 114.0, the ASCII value of <code>'r'</code>? First, the | |
* <code>new Double(0)</code> is convert to primary type <code>double</code>, |
This file contains hidden or 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
/** | |
* {@link Integer} will cache the integers between -128 and 127 (inclusive). See | |
* {@link Integer#valueOf(int)} for detail implementation. | |
* | |
* @author khotyn | |
* | |
*/ | |
public class IntegerTest { | |
public static void main(String[] args) { |
This file contains hidden or 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
from xml.dom.minidom import getDOMImplementation, parse, parseString | |
import zipfile | |
import sys | |
font = """\n<style type='text/css'>\n | |
@page {\n | |
margin-bottom: 5pt;\n | |
margin-top: 5pt\n | |
}\n | |
@font-face {\n |
This file contains hidden or 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
王 | |
江 | |
周 | |
胡 | |
刘 | |
李 | |
吴 | |
毛 | |
温 | |
习 |
NewerOlder