 
 (deftest test_somegetkey
   (is (= [randomsymbo12892712391 'randomsymbo12892712391] 
-        (getKeyIfExists randomsymbo12892712391) 
-        (getExistingKey randomsymbo12892712391)))
+        (getVectorKeyIfExists randomsymbo12892712391) 
+        (getExistingKeyVec randomsymbo12892712391)))
   
   (is (= ['randomsymbo12892712391 randomsymbo12892712391] 
-        (getKeyIfExists 'randomsymbo12892712391) 
-        (getExistingKey 'randomsymbo12892712391)))
+        (getVectorKeyIfExists 'randomsymbo12892712391) 
+        (getExistingKeyVec 'randomsymbo12892712391)))
   (isthrown? exceptionThrownWhenMalformedInputPassed 
-        (getKeyIfExists 1) )
-  (isthrown? exceptionThrownWhenMalformedInputPassed (getExistingKey 1))
+        (getVectorKeyIfExists 1) )
+  (isthrown? exceptionThrownWhenMalformedInputPassed (getExistingKeyVec 1))
   
   (isthrown? exceptionThrownWhenKeyDoesNotExist
-    (getExistingKey (gensym 'inexistentsymbol))
+    (getExistingKeyVec (gensym 'inexistentsymbol))
     )
   )
 

(def exceptionThrownWhenMalformedInputPassed
  AssertionError)

(defn getKeyIfExists
"
you may pass: symbol or keyword
ie.
(getKeyIfExists a) where a evals to :a or 'a
(getKeyIfExists 'a)
(getKeyIfExists :a)
returns:
nil if not exists,
[key val] if exists, where key is the same as what you passed evaluated to

    )
  )

(defn getExistingKey
  [key]
  (let [[k v] (getExistingKeyVec key)
        ]
    (cond (keyword? k)
      k
      :else
      v
      )
    )
  )

(deftest test_get1
  (is (= [:a 1] (getExistingKeyVec {:a 1} :a )))
  (is (= [:a nil] (getExistingKeyVec {:a nil} :a )))
  (is (= [:a 1] (getVectorKeyIfExists {:a 1} :a )))
  (is (= [:a nil] (getVectorKeyIfExists {:a nil} :a )))
  (is (nil? (getVectorKeyIfExists {:a nil} :b )))
  (isthrown? exceptionThrownWhenKeyDoesNotExist 
    (getExistingKeyVec {:a nil} :b ))
  )


