-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
249 lines (163 loc) · 7.96 KB
/
index.html
File metadata and controls
249 lines (163 loc) · 7.96 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
<!DOCTYPE HTML>
<html>
<head>
<script data-cfasync="false" type="text/javascript" src="//use.typekit.net/axj3cfp.js"></script>
<script data-cfasync="false" type="text/javascript">try{Typekit.load();}catch(e){}</script>
<meta charset="utf-8">
<title>From physics to Big Data, functional programming, and more. | Stack Unwinding</title>
<meta name="author" content="Chris Jones">
<meta name="description" content="Let’s say you have a list of numbers. What can you do with it? Find its length, map a function over it, add them up, etc. Wouldn’t it be great if …"> <meta name="keywords" content="">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<link href="/atom.xml" rel="alternate" title="Stack Unwinding" type="application/atom+xml">
<link rel="canonical" href="">
<link href="/favicon.png" rel="shortcut icon">
<link href="/stylesheets/screen.css" media="screen, projection" rel="stylesheet" type="text/css">
<!--[if lt IE 9]><script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script type="text/javascript" src="/javascripts/jquery.fancybox.pack.js"></script>
<script language="Javascript" type="text/javascript">
$(document).ready(
function() {
(function($) {
$(".fancybox[data-content-id]").each(function() {
this.href = $(this).data('content-id');
});
$(".fancybox").fancybox({
beforeLoad: function() {
var el,
id = $(this.element).data('title-id');
if (id) {
el = $('#' + id);
if (el.length) {
this.title = el.html();
}
}
if ($(this).data('content')) {
this.content = $(this).data('content');
}
},
helpers: {
title: {
type: 'inside'
}
}
});
})(jQuery);
}
);
</script>
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
extensions: ["tex2jax.js","fp.js"],
jax: ["input/TeX", "output/HTML-CSS"],
tex2jax: {
inlineMath: [ ['$', '$'] ],
displayMath: [ ['$$', '$$']],
processEscapes: true,
skipTags: ['script', 'noscript', 'style', 'textarea', 'pre', 'code']
},
messageStyle: "none",
"HTML-CSS": { preferredFont: "TeX", availableFonts: ["STIX","TeX"] },
TeX: {extensions: ["xypic.js", "AMSmath.js","AMSsymbols.js"]}
});
</script>
<script src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?
config=TeX-AMS_HTML" type="text/javascript"></script>
<script src="/javascripts/fp.js"
type="text/javascript"></script>
<script src="/javascripts/xypic.js"
type="text/javascript"></script>
</head>
<body>
<header id="header" class="inner"><h1><a href="/">Stack Unwinding</a></h1>
<h4>From physics to Big Data, functional programming, and more.</h4>
<nav id="main-nav"><ul>
<li><a href="/">Blog</a></li>
<li><a href="/about">About</a></li>
<li><a href="/portfolio">Portfolio</a></li>
<li><a href="/archives">Archive</a></li>
</ul>
</nav>
<nav id="mobile-nav">
<div class="alignleft menu">
<a class="button">Menu</a>
<div class="container"><ul>
<li><a href="/">Blog</a></li>
<li><a href="/about">About</a></li>
<li><a href="/portfolio">Portfolio</a></li>
<li><a href="/archives">Archive</a></li>
</ul>
</div>
</div>
<div class="alignright search">
<a class="button"></a>
<div class="container">
<form action="http://google.com/search" method="get">
<input type="text" name="q" results="0">
<input type="hidden" name="q" value="site:chrislambda.github.io">
</form>
</div>
</div>
</nav>
</header>
<div id="content" class="inner">
<article class="post">
<h2 class="title">
<a href="/blog/2014/01/30/catamorphisms-in-15-minutes/">
Catamorphisms in 15 Minutes!</a>
</h2>
<div class="entry-content">
<p>Let’s say you have a list of numbers. What can you do with it? Find its length, map a function over it, add them up, etc. Wouldn’t it be great if there were <em>one function to rule them all</em>, a function that generalizes what you can do with a list? In many languages, there is a higher-order function called <code>fold</code> that encapsulates a pattern of <strong>structural recursion</strong> over recursive structures: to specify a function on a list, you specify two exhaustive cases: what to do to an empty list, and what to do with any other list. A generalization of <em>this</em> generalization is the notion of a catamorphism, which is what I’m writing about today.</p>
<a href="/blog/2014/01/30/catamorphisms-in-15-minutes/" class="more-link">More! →</a>
</div>
<div class="meta">
<div class="date">
<time datetime="2014-01-30T20:53:57-05:00" pubdate data-updated="true">Jan 30<span>th</span>, 2014</time></div>
<div class="tags">
<a class='category' href='/blog/categories/haskell/'>Haskell</a>, <a class='category' href='/blog/categories/algebra/'>algebra</a>, <a class='category' href='/blog/categories/catamorphism/'>catamorphism</a>, <a class='category' href='/blog/categories/category/'>category</a>, <a class='category' href='/blog/categories/functional/'>functional</a>, <a class='category' href='/blog/categories/functor/'>functor</a>
</div>
<span class="comments"><a href="/blog/2014/01/30/catamorphisms-in-15-minutes//index.html#disqus_thread">Comments</a></span>
</div></article>
<article class="post">
<h2 class="title">
<a href="/blog/2014/01/20/from-coding-to-calculating/">
From Coding to Calculating</a>
</h2>
<div class="entry-content">
<p>Like many aspiring software developers and computer scientists, I wanted to improve my art by going through <a href="http://mitpress.mit.edu/sicp/full-text/book/book.html" title="SICP">Structure and Interpretation of Computer Programs</a>. I fully expected to emerge from it all with Sherlock Holmes-esque abilities in programming. Yeah, that was about 7 years ago. Still, every so often, I’ll do some of the exercises and search online to see how my answers compared to others’.</p>
<a href="/blog/2014/01/20/from-coding-to-calculating/" class="more-link">More! →</a>
</div>
<div class="meta">
<div class="date">
<time datetime="2014-01-20T17:18:10-05:00" pubdate data-updated="true">Jan 20<span>th</span>, 2014</time></div>
<div class="tags">
<a class='category' href='/blog/categories/2-28/'>2-28</a>, <a class='category' href='/blog/categories/haskell/'>Haskell</a>, <a class='category' href='/blog/categories/lisp/'>Lisp</a>, <a class='category' href='/blog/categories/scheme/'>Scheme</a>, <a class='category' href='/blog/categories/functional/'>functional</a>, <a class='category' href='/blog/categories/sicp/'>sicp</a>
</div>
<span class="comments"><a href="/blog/2014/01/20/from-coding-to-calculating//index.html#disqus_thread">Comments</a></span>
</div></article>
<nav id="pagenavi">
<div class="center"><a href="/archives">Blog Archives</a></div>
</nav></div>
<footer id="footer" class="inner">Copyright © 2014
Chris Jones
<br>
Powered by Octopress.
</footer>
<script src="/javascripts/slash.js"></script>
<script src="/javascripts/jquery.fancybox.pack.js"></script>
<script type="text/javascript">
(function($){
$('.fancybox').fancybox();
})(jQuery);
</script> <!-- Delete or comment this line to disable Fancybox -->
<script type="text/javascript">
var disqus_shortname = 'stackunwinding';
var disqus_script = 'count.js';
(function () {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = '//' + disqus_shortname + '.disqus.com/' + disqus_script;
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
}());
</script>
</body>
</html>