Skip to content

Instantly share code, notes, and snippets.

@actsasgeek
Created January 22, 2012 01:52
Show Gist options
  • Select an option

  • Save actsasgeek/1655048 to your computer and use it in GitHub Desktop.

Select an option

Save actsasgeek/1655048 to your computer and use it in GitHub Desktop.
evaluating a string
(defn get-user-command [game-state]
(let [ command (read-line)
[function & args] (conj (into [] (.split command " ")) "game-state")]
(do
(println function args)
(apply (symbol function) args))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment