Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 849723
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T07:08:58+00:00 2026-05-15T07:08:58+00:00

I had never really thought about whether a symbol could be a number in

  • 0

I had never really thought about whether a symbol could be a number in Lisp, so I played around with it today:

> '1
1
> (+ '1 '1)
2
> (+ '1 1)
2
> (define a '1)
> (+ a 1)
2

The above code is scheme, but it seems to be roughly the same in Common Lisp and Clojure as well. Is there any difference between 1 and quoted 1?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T07:08:59+00:00Added an answer on May 15, 2026 at 7:08 am

    Well, they are in fact very different. '1 is however precisely the same as (quote 1). (car ''x) evaluates to the symbol ‘quote’.

    1 is an S-expression, it’s the external representation of a datum, a number 1. To say that 1 is a ‘number-object’ or an S-expression to enter that object would both be acceptable. Often it is said that 1 is the external representation for the actual number object.

    (quote 1) is another S-expression, it’s an S-expression for a list whose first element is the symbol ‘quote’ and whose second element is the number 1. This is where it’s already different, syntactic keywords, unlike functions, are not considered objects in the language and they do not evaluate to them.

    However, both are external representations of objects (data) which evaluate to the same datum. The number whose external representation is 1, they are however most certainly not the same objects, the same, code, the same datum the same whatever, they just evaluate to the very same thing. Numbers evaluate to themselves. To say that they are the same is to say that:

    (+ 1 (* 3 3))
    

    And

    (if "Strings are true" (* 5 (- 5 3)) "Strings are not true? This must be a bug!")
    

    Are ‘the same’, they aren’t, they are both different programs which just happen to terminate to the same value, a lisp form is also a program, a form is a datum which is also a program, remember.

    Also, I was taught a handy trick once that shows that self-evaluating data are truly not symbols when entered:

    (let ((num 4))
      (symbol? num) ; ====> evaluates to #f
      (symbol? 'num) ; ====> evaluates to #t
      (symbol? '4) ; ====> evaluates to #f
      (symbol? '#\c) ; #f again, et cetera
      (symbol? (car ''x)) ; #t
      (symbol? quote) ; error, in most implementations
    )
    

    Self evaluating data truly evaluate to themselves, they are not ‘predefined symbols’ of some sorts.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Here's an interesting question I never really thought about until I had a conversation
I never really dealt with NLP but had an idea about NER which should
I'd always heard of the JDic project being around, but never really had a
I had never thought about this before, but lately I've been worried about something.
I've never had the need to really ever use any of the .NET Data
This seems really easy (I've done it a million times and never had a
Ok I have this problem that I've never had before, it's really bugging me.
I'm using PHPMailer for a while now and never really had any problems, but
I've never really had this error before but I am doing a rather large
I've never really had to play with classes but am looking to use php-ews

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.