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
function ( | |
a, // A Nodelist whichto use as root | |
b, // iterate-placeholder | |
c, // elem-placeholder | |
d, // tags-placeholder | |
e, // tag-placeholder | |
f // parent-placeholder | |
) { | |
for (b = 0; c = a[b++]; |
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
/** | |
* [BreakBlock description] | |
*/ | |
function BreakBlock(row, col){ | |
this.data = []; | |
this.position = [ 0, 0 ]; | |
this.direction = BreakBlock.DIRECTION.NE; | |
}; | |
BreakBlock.AXIS = { |
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
App({ | |
/** | |
* [request description] | |
* @param {[type]} method [description] | |
* @param {[type]} url [description] | |
* @param {[type]} data [description] | |
* @param {[type]} header [description] | |
* @return {[type]} [description] | |
*/ |
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
for(var n=8888,c=0; n; c+=(n=n>>1)&1){ c; }; |
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
<style> | |
body{ | |
margin: 100px; | |
text-align: center; | |
} | |
[tooltip]{ | |
position: relative; | |
} |
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
// | |
// function fn(n){ | |
// if(n > 100) return n; | |
// return fn(n + (n + 1)); | |
// }; | |
function pad(s, n){ | |
while(n--) s = '0' + s; | |
return s; | |
}; |
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
for(var y=0;y<=10;y++){ | |
var arr = []; | |
for(var x=0;x<5;x++) arr.push( Math.max(0, Math.round((y / 2) - x)) ); | |
console.log('%j\t> ', y, arr); | |
} |
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
<html> | |
<head> | |
<meta charset="utf8" /> | |
<meta name="viewport" content="width=device-width"> | |
<title>MaoYan Toolbox</title> | |
<style> | |
body{ | |
width: 50%; | |
margin: auto; | |
text-align: center; |
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 | |
# | |
# example: | |
# | |
# curl -s https://gist.githubusercontent.com/song940/332b80f24e7f203987eff11fc6765bd8/raw/progressbar.sh | sh | |
# | |
function ProgressBar(){ | |
let max=$1 |
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
# Github CDN Server | |
199.27.76.133 assets-cdn.github.com | |
23.235.46.133 camo.githubusercontent.com | |
23.235.46.133 avatars0.githubusercontent.com | |
23.235.46.133 avatars1.githubusercontent.com | |
23.235.46.133 avatars2.githubusercontent.com | |
23.235.46.133 avatars3.githubusercontent.com | |
23.235.46.133 avatars4.githubusercontent.com |