2014-07-09から1日間の記事一覧

140709 水曜 Emacs Lisp で無名関数

休憩時間に scratch バッファで Emacs Lisp を少し触ってみた。 関数定義 関数は defun で定義する (defun hoge (x y) (+ x y)) (hoge 2 3) ;; -> 5 (defun square (x) (* x x)) (square 6) ;; -> 36 無名関数 lambda lambda で無名関数として書くと、それぞ…