ReachAndre
2007-04-13, 05:51 PM
Hello all, I am trying to creaet a lisp with an even number as an output. How would I round up to the nearest EVEN number? (always round up)
Here is my code so far
(defun c:cool (/ inputval)
(setq inputval (getreal "input value: "))
(setq output (* inputval 0.32))
(Somehow make even whole number)
(alert (strcat (rtos evened 2 0) " of input"))
(princ)
)Thank you all in advance,
Andre
[ Moderator Action = ON ] What are [ CODE ] tags... (http://forums.augi.com/misc.php?do=bbcode#code) [ Moderator Action = OFF ]
Here is my code so far
(defun c:cool (/ inputval)
(setq inputval (getreal "input value: "))
(setq output (* inputval 0.32))
(Somehow make even whole number)
(alert (strcat (rtos evened 2 0) " of input"))
(princ)
)Thank you all in advance,
Andre
[ Moderator Action = ON ] What are [ CODE ] tags... (http://forums.augi.com/misc.php?do=bbcode#code) [ Moderator Action = OFF ]