;example autolisp expressions
(setq x (* 2 (+ 3 2)))
(setq width 25.0)
Once these things have been typed in, you can use !x or !width at prompts to pipe the values into autocad prompts.
For example:
Command: circle Specify center point for circle or [3P/2P/Ttr (tan tan radius)]: Specify radius of circle or [Diameter] <5.0000>: !width 25.0
Here is an example of a function:
(defun double (x)(* 2 x))
If one types (or pastes that into the command line, they can do this:
(double 10)
and see 20 as a result

Here is a function that makes an abbreviation for an autocad command:
(defun c:r ()(command "3dforbit"))
Here is something to help build these abbreviations:
Click here for abbreviation generator