Skip to content

Tag Archives: Code

What is “real code”?

One common complaint about non-mainstream programming languages is that there hasn’t been any “real code” written in that particular language. One response to this is the Practical Common Lisp book.
Whether or not a MP3 database or a spam filter is “real code” is up for debate. Nonetheless, based on the success of the book, [...]

An implementation of the map function in F Sharp

Here is how map may be implemented in F Sharp. (At the very least, it is my attempt at implementing it!)
You can run this in the interactive shell.

#light;;
 
let rec my_map fn xs =
match xs with
| first::rest -> (fn first) :: (my_map fn rest)
| [...]