From: Ramakrishnan Muthukrishnan Date: Sat, 10 Jul 2010 06:56:14 +0000 (+0530) Subject: solution to 2.26 X-Git-Url: https://git.rkrishnan.org/vdrive/%22news.html/simplejson//%22doc.html/%22?a=commitdiff_plain;h=b8e79424d3b5937daa752ab9e30122a10d56b5ea;p=sicp.git solution to 2.26 --- diff --git a/src/sicp/ex2_26.clj b/src/sicp/ex2_26.clj new file mode 100644 index 0000000..0825ed8 --- /dev/null +++ b/src/sicp/ex2_26.clj @@ -0,0 +1,15 @@ +(ns sicp.ex2_26) + +(def x (list 1 2 3)) +(def y (list 4 5 6)) + +;; (append x y) will produce (1 2 3 4 5 6) +;; (cons x y) will produce ((1 2 3) 4 5 6) +;; (lis x y) => ((1 2 3) (4 5 6)) + +(concat x y) +;;=> (1 2 3 4 5 6) +(cons x y) +;;=> ((1 2 3) 4 5 6) +(list x y) +;;=> ((1 2 3) (4 5 6)) \ No newline at end of file