This is basically exactly what I've been thinking about. I was going to get the cheatsheet into a place where I could use it easily so I could ask:
(sente [1 2 3]) Since [1 2 3] is a clojure.lang.PersistentVector, we could return functions that operate specifically on that type. But the ideal case is exactly what you're saying, and what I've wanted to figure out for a long time. Kibit seems like a template for doing this sort of thing, but it will take a lot of training to get it to be useful. It's certainly a non-trivial problem. '(Devin Walters) On Monday, March 26, 2012 at 4:07 PM, Rostislav Svoboda wrote: > > if there are any strong feelings about how to make the cheatsheet more of a > > modular, queryable structure than it currently is. > > > The key question is "Why do we need a cheatsheet"? Well, the learning > curve is steep. I.e. there are things like [1] quite many functions > and [2] they are hard to remember and [3] the REPL is by no means > beginner friendly etc. > > What can be done about it ? > We can reduce the amount of functions. I doubt this would work. Or we > develop tools like this queryable cheatsheets with tooltips etc. Or... > well, basically most of the time I personally have a problem like: > > I have [1 2 3 4 5 6 7 8 9] and (a b c d). How do I make (:a [1 2] :b > [4 5] } {:c [6 7] [:d {8 9}]) from it? > > I was thinking about a clojure function which applies some frequently > used patterns (combinations of map, apply, into, assoc, vector, list > etc.) on my input parameter and compares the result with the last > parameter. And it prints the combination if they are equal or gives me > the best nearest guess. I realized it's a job for a macro... something > like discussed on > http://www.learningclojure.com/2010/09/clojure-macro-tutorial-part-i-getting.html > > What do you think about that? > > Bost > > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to clojure@googlegroups.com > (mailto:clojure@googlegroups.com) > Note that posts from new members are moderated - please be patient with your > first post. > To unsubscribe from this group, send email to > clojure+unsubscr...@googlegroups.com > (mailto:clojure+unsubscr...@googlegroups.com) > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en > > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en