\s+ #ignore whitespace
{ "{"
} "}"
[ "["
] "]"
, ","
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
#| | |
usage: | |
(funcall (self-lambda (n) (if (> n 0) | |
(self (- n 1)) | |
n)) | |
5) | |
|# | |
(defmacro self-lambda (param-lst &rest body) | |
(let ((fn (gensym))) |
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
(defun pin (atm) | |
(cond | |
((eql atm 'CA) 'P6);seg14 display | |
((eql atm 'CB) 'N4) ((eql atm 'CC) 'V5) ((eql atm 'CD) 'T5) ((eql atm 'CE) 'U7) | |
((eql atm 'CF) 'R3) ((eql atm 'CG1) 'N5) ((eql atm 'CG2) 'R5) ((eql atm 'CH) 'T3) ((eql atm 'CJ) 'T3) | |
((eql atm 'CK) 'V4) ((eql atm 'CL) 'V7) ((eql atm 'CM) 'R7) ((eql atm 'CN) 'T7) ((eql atm 'DP) 'U5) | |
((eql atm 'S1) 'N3);push button | |
((eql atm 'S2) 'P4) ((eql atm 'S3) 'P3) ((eql atm 'S4) 'L6) ((eql atm 'S5) 'M5) | |
((eql atm 'S6) 'U2) ((eql atm 'S7) 'U1) ((eql atm 'S8) 'T2) | |
((eql atm 'D1) 'K4);LED |
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
//114.34.230.1 | |
//192.168.1.100 | |
var http = require('http'); | |
var fs = require('fs'); | |
var url = require('url'); | |
http.createServer(function (req, res) { | |
var pathname = url.parse(req.url).pathname; | |
console.log(pathname); | |
if(pathname=='/') |
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
genpair = (num)-> | |
return [] if num<=1 | |
result = [] | |
for i in [0..num-2] | |
result = result.concat ([i,n] for n in [i+1..num-1]) | |
return result |
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
Object.prototype.toString = function() { | |
var key, result, val; | |
result = ["{"]; | |
for (key in this) { | |
val = this[key]; | |
result = result.concat(key, ":", val, ","); | |
} | |
result.pop(); | |
return (result.concat("}")).join(""); | |
}; |
NewerOlder