Another question from the noob gallery: (def the-example (value1 (o value2 "wahoo!")
(o value3 "ugh!")(o value4 "omg!"))
(prn "Value1: " value1)
(prn "Value2: " value2)
(prn "Value3: " value3)
(prn "Value4: " value4)
)
I was kinda hoping passing nil in for value2 would mean the function would use the default parameter for the argument.but nope: arc> (the-example "Results" nil "wowser!" "cha-ching!!!") Value1: Results
Value2: nil
Value3: wowser!
Value4: cha-ching!!!
How does one do this without writing a bunch of clutter code conditional statements to handle nils ? Can it be done?Also .... one more quick question: is it possible to have a prn statement embedded into an html output function that only outputs to the terminal not the browser ? I'm sooo tired of adding and removing test statements from the function. hehe :) I hope that last question made sense.... Thanks,
T. |