Common Lisp beginer If else
by Petr Strajt from LinuxQuestions.org on (#5N7GG)
Hi everybody,
I am beginer in Common Lisp. I am trying to create a code that asks the user if he wants to run firefox browser with y/n answer.
I have this code
Code:(print"Do you want to run Firefox? y/n")
(setq answer(read))
(if (= answer "y"))
(run-program "firefox")
than
(/= answer y)
(print "something")If I run this code I receive this error message: *** - EVAL: too few parameters for special operator IF: (IF (= ANSWER "y"))
How to resolve this issue? Thank you for your advice
I am beginer in Common Lisp. I am trying to create a code that asks the user if he wants to run firefox browser with y/n answer.
I have this code
Code:(print"Do you want to run Firefox? y/n")
(setq answer(read))
(if (= answer "y"))
(run-program "firefox")
than
(/= answer y)
(print "something")If I run this code I receive this error message: *** - EVAL: too few parameters for special operator IF: (IF (= ANSWER "y"))
How to resolve this issue? Thank you for your advice