The Artima Developer Community
Sponsored Link

Java Buzz Forum
(apparently (am I Lisp))

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Brian McCallister

Posts: 1282
Nickname: frums
Registered: Sep, 2003

Brian McCallister is JustaProgrammer who thinks too much.
(apparently (am I Lisp)) Posted: Nov 3, 2004 5:27 AM
Reply to this message Reply

This post originated from an RSS feed registered with Java Buzz by Brian McCallister.
Original Post: (apparently (am I Lisp))
Feed Title: Waste of Time
Feed URL: http://kasparov.skife.org/blog/index.rss
Feed Description: A simple waste of time and weblog experiment
Latest Java Buzz Posts
Latest Java Buzz Posts by Brian McCallister
Latest Posts From Waste of Time

Advertisement

You are... Lisp!

(define bottles
  (lambda (n)
    (cond ((= n 0) (display "No more bottles"))
        ((= n 1) (display "One bottle"))
        (else (display n) (display " bottles")))
    (display " of beer")))

(define beer
  (lambda (n)
    (if (> n 0)
      (begin
        (bottles n) (display " on the wall") (newline)
        (bottles n) (newline)
        (display "Take one down, pass it around") (newline)
        (bottles (- n 1)) (display " on the wall") (newline)
        (newline)
        (beer (- n 1))))))

(beer 99)

What programming language are you?

This one is pretty manipulable if you know anything bout languages, and isn't all that clever, but is fun anyway =)

Read: (apparently (am I Lisp))

Topic: [Oct 25, 2004 12:32 PDT] 10 Links Previous Topic   Next Topic Topic: Vulnerability hits Java for cell phones

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use