Jump to content

what's wrong?


Came

Recommended Posts

i am new to this

 

this is problem

 

 

Command: (+ .618 1)

; error: misplaced dot on input

 

Command: (1/(+0.618 1))

; error: bad function: 0.618

 

Command: (1/(+5 1))

; error: bad function: 5

 

am trying to type that simple command and i cep getting error

 

 

 

 

am learning basic

Link to comment
Share on other sites

(+ 0.618 1) ;notice the zero in front of the dot
(/ 1 (+ 0.618 1)); almost always a function after an opening parenthesis

Link to comment
Share on other sites

thanks

 

nervous i think :glare: it s first time, i will post in near future some similar

 

question

 

 

just started to reading and practicing :glare:

 

i got

 

Command: (/ 1 (+ 0.618 1))

0.618047

 

Command: (+ 0.618 1)

1.618

 

i was in that problem about 30 min

 

 

 

works :oops:

Link to comment
Share on other sites

No problem Came,

 

I'm sure most of us have been there. :P

 

1 more point I would also stress is that when specifying the numbers, specify them as reals and not integers (particularly when doing division), as, otherwise you will get weird answers like say:

 

(/ 1 4) = 0

 

Whereas

 

(/ 1. 4.) = 0.25

 

and

 

(/ 1.0 4.0) = 0.25

 

Hope this helps!

Link to comment
Share on other sites

of course it does any advice or reply is worth of goold :roll:

 

 

 

 

 

when start to understand this lisp

 

then we will talk about gold

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...