Lisp is a (family of) general purpose functional programming language(s), based on the lambda calculus, and with the ability to manipulate source code as a data structure.

learn more… | top users | synonyms

-1
votes
0answers
15 views

Editing Emacs Save Function to Execute Script When in Certain Mode (.orgmode) [migrated]

I want to let my Emacs execute a bash script I wrote, whenever I hit C-x s to save, when I'm in .org mode. The script automatically syncs the file I am saving to my Raspberry Pi. It expects the buffer ...
6
votes
1answer
302 views

The Lisp in Gnu

Since the GNU project is celebrating its anniversary, and the initial announcement for GNU is linked to (http://www.gnu.org/gnu/initial-announcement.en.html) all over the place, I reread it and I ...
0
votes
3answers
162 views

Reference counting & GC in LISP [closed]

What is the main method for reclaiming the memory in LISP? Does LISP really need garbage collection? Would not reference counts suffice? I just wanted to know whether reference counts are enough ...
11
votes
0answers
520 views

How to implement a branch-and-bound in a functional programming language?

I am trying to write a branch and bound search on the set of all functions f: D -> R, where the domain size is small (|D| ~ 20) and the range is much bigger (|R| ~ 2^20). Initially, I came up with the ...
31
votes
2answers
6k views

Which Common Lisp implementation to use?

There seems to be an immediate problem with starting to develop in Common Lisp: choosing an implementation. What should one take into account, and how much weight should it bear when considering a CL ...
13
votes
5answers
2k views

In what programming language did “let” first appear?

I was wondering about the origins of the "let" used in Lisp, Clojure, and Haskell. Does anyone know which language it appeared in first?
2
votes
1answer
227 views

How do you make decorators as powerful as macros?

Quick background: I am designing a Pythonic language that I want to be as powerful as Lisp while remaining easy to use. And by "powerful", I mean "flexible and expressive". I've just been introduced ...
4
votes
5answers
2k views

Compiler design in Lisp

With some googling, I could easily find some documents in compiler design in C, Java, and C# and even in Haskell, but not in Lisp except implementing Scheme/Lisp in Lisp. Is Lisp not so popular in ...
1
vote
1answer
190 views

Object-Oriented equivalent of LISP's progn function?

I'm currently writing a LISP parser that iterates through some AutoLISP code and does its best to make it a little easier to read (changing prefix notation to infix notation, changing setq assignments ...
13
votes
5answers
6k views

Recent programming language for AI? [closed]

For a few decades the programming language of choice for AI was either Prolog or LISP, and a few more others that are not so well known. Most of them were designed before the 70's. Changes happens a ...
1
vote
1answer
158 views

What is the most efficient method in converting AutoLISP legacy code to C#?

I am engaged in a project that works mainly in AutoCAD to design and manufacture prefabricated building components such as roofing trusses. One of our goals is to redesign a program that was written ...
8
votes
5answers
957 views

Wrapping my mind around prefix notation?

I'm reading about LISP. I understand how prefix notation works at a certain level, but I was wondering if there are any tricks to making it intuitive.
16
votes
5answers
2k views

Why is studying an lisp interpreter in lisp so important?

I have seen many CS curriculums and learning suggestions for new programmers that call for the aspiring programmer to study a lisp interpreter that is specifically written in lisp. All these sites ...
5
votes
1answer
197 views

What features does MIT-Scheme have that make it ideal for SICP?

I've been thinking about trying to get through the SICP again, this time well-armed with a better idea of what the SICP is meant to accomplish, and being older and wiser than my first attempt back in ...
21
votes
5answers
5k views

Is is preferable to design top down or bottom up?

As I understand, top-down design is by refining the abstract high level concept into smaller concrete and comprehensible parts, until the smallest building block is defined. On the other hand, bottom ...
5
votes
1answer
418 views

What's the difference between lists constructed by quote and those constructed by cons in Scheme?

(define ls1 '((1 . 2) 1 . 2)) (set-car! (car ls1) 6) ls1 (define ls2 (cons '(1 . 2) '(1 . 2))) (set-car! (car ls2) 6) ls2 After set-car!ing, ls1 will be ((6 . 2) 1 . 2) and ls2 ((6 . 2) 6 . 2). It ...
4
votes
3answers
355 views

Obscurity of Lisp in collaborative projects [closed]

I'm playing with the idea of learning Scheme but I have a few misgivings. From what I understand Lisp makes heavy use of macros that allow programmers to drastically change the language itself. I ...
10
votes
10answers
2k views

Greenspun's Tenth Rule, does every large project include a Lisp interpreter? [closed]

Greenspun's tenth rule (actually the only rule) states that: Any sufficiently complicated C or Fortran program contains an ad hoc, informally-specified, bug-ridden, slow implementation of half of ...
5
votes
2answers
257 views

Is Lisp the first language to adopt structured programming?

I couldn't find any links or books claiming that Lisp is the first programming language to adopt structured programming (actually, most of them don't even mention Lisp at all), but if conditionals ...
5
votes
3answers
264 views

Multiple Dispatch and CLOS

I have never written software in Common Lisp, but in Scheme and Clojure as well as C++ and Python. Yet I have had a look at the Common Lisp Object System (CLOS) in Common Lisp and Dylan. Now when ...
3
votes
1answer
215 views

How can Lisp produce an iterative process from a recursive procedure?

I am starting to learn Lisp, using the SICP book. The authors mention that a procedure (i.e. function) can be recursive or iterative. Additionally, the process those procedures will generate will also ...
30
votes
6answers
2k views

Does Lisp still have any special feature which has NOT been adopted by other programming languages?

Does Lisp still have any special feature which has NOT been adopted by other programming languages? By Lisp, I mean all the Lisp programming languages as a whole. I've been told how amazing Lisp is ...
18
votes
6answers
3k views

Advantage of Learning Lisp for a Python Programmer

I am primarily a Python, Java, C++ programmer, and I've gained a recent interest in functional language. I'm thinking of picking up a LISP dialect: Clojure. Now, I've been working through tutorials ...
25
votes
10answers
4k views

Would you use (a dialect of) LISP for a real-world application? Where and why?

LISP (and dialects such as Scheme, Common LISP and Clojure) haven't gained much industry support even though they are quite decent programming languages. (At the moment though it seems like they are ...
1
vote
0answers
248 views

Hoes dows the productivity incidence of Lisp and OCaml compare?

I am about to start a new project and I cannot decide if I should pick OCaml or Lisp for the project. My main concern is about the difference of productivity — if any. I program OCaml since 1998 ...
2
votes
2answers
361 views

Lisp/Clojure: Removing unnecessary parentheses through conventions

I am fascinated to Lisp as it is simple yet powerful. I am just a beginner and I know there have been lots of discussions on removing parentheses from Lisp and its dialects. Yet I request Lisp ninja's ...
20
votes
12answers
2k views

Is there a language offering LISP-like macros with a more complex syntax?

LISP's macros are extremely powerful constructs, and the inability to introspect and modify the program itself beyond the method signature level has always struck me as a limitation. Yet I favour ...
-2
votes
3answers
266 views

Why we say Lisp are Human oriented and Fortran are Machine oriented? [closed]

Lisp and Fortran were the trunks of two separate evolutionary trees, one rooted in math and one rooted in machine architecture. I see this in Hackers and Painters: Big Ideas from the ...
2
votes
3answers
511 views

How does a chess engine decide what move to make?

I'm writing a simple chess engine in LISP. I actually know how the engine decide the move, it evaluates and reads some opening books. But that's not what i mean. This is my design. 57 58 59 60 61 62 ...
7
votes
6answers
704 views

Challenges for the experienced coder to learn functional programming? [closed]

What are the challenges that an experienced programmer with the usual C++/UNIX background would face when trying to learn functional programming? The main motive for learning is to gain a fresh ...
9
votes
4answers
956 views

Python decorators and Lisp macros

When looking Python decorators someone made the statement, that they are as powerful as Lisp macros (particularly Clojure). Looking at the examples given in PEP 318 it looks to me as if they are just ...
44
votes
17answers
14k views

Why is Lisp useful? [closed]

Lisp obviously is an advantage for the AI stuff, but it doesn't appear to me that Lisp is any faster than Java, C#, or even C. I am not a master of Lisp, but I find it incredibly difficult to ...
1
vote
4answers
732 views

Why languages that compile to C/C++ generate unreadable, cryptic code?

I'm willing to compile certain language to C or C++ for some speedups. My idea was, though, to generate readable code and use structures such std::vector and similar wherever I can, expecting CLANG to ...
2
votes
2answers
631 views

Ring of numbers where adjacent entries sum up to a prime

Given a number n, find a permutation of the numbers 1...n such that all adjacent entries sum up to primes. If such a permutation does not exist, throw an error. Is there a purely-functional way to do ...
4
votes
1answer
349 views

s expression representation for c

Experimenting with various lisps lately (clojure especially) i have wondered if there are any s expression based representations of (subsets) of c, so you could use lisp/closure to write macros and ...
7
votes
5answers
2k views

XSLT and possible alternatives [closed]

I had a look at XSLT for transforming one XML file into another one (HTML, etc.). Now while I see that there are benefits to XSLT (being a standardized and used tool) I am reluctant for a couple of ...
16
votes
3answers
6k views

What are the advantages of using LISP and Haskell? Will they make me a better programmer? [closed]

I know Lisp and Haskell are functional and logic programming languages respectively, but what exactly does this mean? How do they differ from other languages? I've heard that learning these will make ...
10
votes
3answers
964 views

Is it possible to compile a higher level language to readable C++? [closed]

C++ is a great language in many ways, but some things in particular are cumbersome to write without an IDE. As a VIM user, it would be very interesting if I had access to a higher level language which ...
2
votes
3answers
742 views

Does macros support make Scala a Lisp dialect?

I've read recently that macro support in Scala is now official. I checked the documentation page and they are reminiscent to the LISP ones. In one of his essays Paul Graham writes that when "you add ...
4
votes
2answers
536 views

Is it technically possible to write a JS interpreter using Lisp macro readers, in the browser?

Using macros readers, it's possible to interpret JavaScript, and have it compiled just like normal Common Lisp code. Hence getting the benefits of Lisp implementations, notably their performance. ...
35
votes
4answers
2k views

What does your Lisp workflow look like? [closed]

I'm learning Lisp at the moment, coming from a language progression that is Locomotive BASIC -> Z80 Assembler -> Pascal -> C -> Perl -> C# -> Ruby. My approach is to simultaneously: write a simple ...
25
votes
9answers
2k views

What did Stallman mean in this quote about implementing other languages in Lisp?

I just read the following quote from Stallman as part of a speech he gave many years ago. He's talking about how it is feasible to implement other programming languages in Lisp, but not feasible to ...
7
votes
4answers
790 views

What makes Common Lisp “big”?

I've been learning both Common Lisp and Racket, and one thing that I consistently hear is that Racket is a much "smaller" language than Common Lisp. I was wondering what this really meant. As far as I ...
2
votes
1answer
255 views

Which algorithms typify Lisp's power? [closed]

Similar question here (but not the same) because I am interested in which specific algorithms work particularly well in Lisp. Lisp tutorials always give the example of finding factorials, but wanting ...
8
votes
2answers
1k views

Could we build a functional computer?

As mush as FP has done, in the end, all our programs are structured. That is, it doesn't matter how pure or functional we make a them - they are always translated to assembly, so what actually runs ...
9
votes
2answers
975 views

Are square brackets and curly braces in Clojure still S-expressions?

I am trying to learn Lisp and looking at all the Lisps out there and their differences. I see that in some implementations of Scheme, you can use square brackets interchangeably with round brackets ...
3
votes
3answers
376 views

Is there a way to use a higher level language in a competition that only has C, C++ and Java by default? [closed]

On that competition, you gain access to a system with gcc, vim, emacs and Java. You can't take any file with you and there's no internet access, but you can do whatever you want inside that system. ...
2
votes
4answers
1k views

What are the practical benefits of LISP like syntax which Clojure uses over Java like syntax of Scala?

I spent couple of months learning Scala and got overwhelmed by number of different constructs it had, After looking at partial functions, partially-applied functions, pattern matching, actor syntax, I ...
9
votes
9answers
1k views

Resources for improving your comprehension of recursion? [closed]

I know what recursion is (when a patten reoccurs within itself, typically a function that calls itself on one of its lines, after a breakout conditional... right?), and I can understand recursive ...
3
votes
1answer
814 views

Online courses focussed on learning LISP for beginners? [closed]

I'm looking for an online course that I can use to learn programming using Lisp (especially Scheme), from scratch. I didn't find anything similar on Coursera/Udacity - the only resource I found was on ...