Could you please let me know what’s the usual structure when I want a function to return a small number of items?
I’m thinking that the simplest method is to return a vector and then get values using destructuring.
(defn find-product-price  ;; some code (let [price 111 currency "USD" discounted false] [price currency discounted])) (defn get-message-for-customer  (let [[price currency discounted] (find-product-price)] (if discounted (str "Discount " price " " currency) (str "The customer will pay " price " " currency)))) (get-message-for-customer) ;; => "The customer will pay 111 USD"
But somewhere (I don’t remember where) I read that getting values from a vector by indexing it is not the proper way. So should I rather use Map? If not how many elements are still OK and how many should rather be returned as a Map?