lisp

Using Lisp in C#

As a lot of people pointed out in this question, Lisp is mostly used as a learning experience. Nevertheless, it would be great if I could somehow use my Lisp algorithms and combine them with my C# programs. In college my profs never could tell me how to use my Lisp routines in a program (no, not writing a GUI in Lisp, thank you). So how...

What languages implement features from functional programming?

Lisp developed a set of interesting language features quite early on in the academic world, but most of them never caught on in production environments. Some languages, like JavaScript, adapted basic features like garbage collection and lexical closures, but all the stuff that might actually change how you write programs on a large scal...

Which library should I use to generate RSS in Common Lisp?

What's the best library to use to generate RSS for a webserver written in Common Lisp? ...

How do I display an image with ltk?

I have written code to read a windows bitmap and would now like to display it with ltk. How can I construct an appropriate object? Is there such functionality in ltk? If not how can I do it directly interfacing to tk? ...

macro support in F#

After reading Practical Common Lisp I finally understood what the big deal about macros was, and I have been looking for a language for the .NET platform that supports this. There are a few lisp dialects for .NET but from what I have been able to gather all are either very beta or abandoned. Recently my interest has been sparked by Cloju...

Using Vim for Lisp development

I've been using Lisp on and off for a while but I'm starting to get more serious about doing some "real" work in Lisp. I'm a huge Vim fan and was wondering how I can be most productive using Vim as my editor for Lisp development. Plugins, work flow suggestions, etc. are all welcome. Please don't say "use emacs" as I've already ramped up...

How do I append to an alist in scheme?

Adding an element to the head of an alist (Associative list) is simple enough: > (cons '(ding . 53) '((foo . 42) (bar . 27))) ((ding . 53) (foo . 42) (bar . 27)) Appending to the tail of an alist is a bit trickier though. After some experimenting, I produced this: > (define (alist-append alist pair) `(,@alist ,pair)) > (alist-append ...

I need to join two lists, sort them and remove duplicates. Is there a better way to do this?

I have two unsorted lists and I need to produce another list which is sorted and where all the elements are unique. The elements can occur multiple times in both lists and they are originally unsorted. My function looks like this: (defun merge-lists (list-a list-b sort-fn) "Merges two lists of (x, y) coordinates sorting them and r...

Is it correct to use the backtick / comma idiom inside a (loop ...)?

I have some code which collects points (consed integers) from a loop which looks something like this: (loop for x from 1 to 100 for y from 100 downto 1 collect `(,x . ,y)) My question is, is it correct to use `(,x . ,y) in this situation? Edit: This sample is not about generating a table of 100x100 items, the co...

How do I access a char ** through ffi in plt-scheme?

I'm mocking about with plt-scheme's ffi and I have a C-function that returns a char ** (array of strings). If I declare my function as (_fun _pointer -> _pointer), how do I convert the result to a list of strings in scheme? Here are the relevant C-declarations: typedef char **MYSQL_ROW; /* return data as array of strings */ // ... MY...

Practical example of Lisp's flexibility?

Someone is trying to sell Lisp to me, as a super powerful language that can do everything ever, and then some. Can anyone provide a practical code example of Lisp's power?(Preferably alongside equivalent logic coded in a regular language.) ...

Why isn't LISP more widely used?

I've heard a lot of people espouse the capabilities of LISP and its omnipotent macros. If LISP is such a great language, why isn't it being adopted more? What problems is LISP facing that is holding it back from (re)emerging as popular language? Is it something about LISP itself ("those brackets!" isn't the answer, is it?!), or its compe...

Why are fixnums in emacs only 29 bits?

And why don't they change it? Edit: The reason ask is because I'm new to emacs and I would like to use Emacs as a "programmer calculator". So, I can manipulate 32-bit & 64-bit integers and have them behave as they would on the native machine. ...

Are there any High Level, easy to install GUI libraries for Common Lisp?

Are there any good, cross platform (SBCL and CLISP at the very least) easy to install GUI libraries? ...

How do I take a slice of a list (A sublist) in scheme?

Given a list, how would I select a new list, containing a slice of the original list (Given offset and number of elements) ? EDIT: Good suggestions so far. Isn't there something specified in one of the SRFI's? This appears to be a very fundamental thing, so I'm surprised that I need to implement it in user-land. ...

Common Lisp or Scheme?

Which would you recommend learning, CL or Scheme? What are the pros and cons of each, compared to eachother? ...

What are the main differences between CLTL2 and ANSI CL?

Any online links / resources? ...

How do I use (require :PACKAGE) in clisp under Ubuntu Hardy?

I am trying to evaluate the answer provided here, and am getting the error: "A file with name ASDF-INSTALL does not exist" when using clisp: dsm@localhost:~$ clisp -q [1]> (require :asdf-install) *** - LOAD: A file with name ASDF-INSTALL does not exist The following restarts are available: ABORT :R1 ABORT Break 1 [2]> :r1...

What's a good Common Lisp implementation for Windows?

What's your favourite? See also this related question. ...

Are there any Common Lisp implementations for .Net?

Related to my other CL question. ...