Re: create vector from other vector and indices

2018-02-13 Thread Matching Socks
user> (def v [:a :b :c :d]) #'user/v user> (mapv v [3 1 2 0]) [:d :b :c :a] -- 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

Re: Help API

2018-02-13 Thread Mortimer Cladwell
JavaHelp will work. Details here On Wednesday, December 27, 2017 at 8:17:09 AM UTC-5, Mortimer Cladwell wrote: > > I am looking for a help api for my clojure application, something that > will pop up when the user selects "Help" from

Re: tlc Expect like library?

2018-02-13 Thread Andy Fingerhut
Google searches for the terms: java tcl expect turn up a few things that appear to be integrations of existing Tcl/Expect into the JVM via native interfaces like JNI. There might also be a "native Java" version available that way. The up side of wrapping an existing implementation is that it

Re: tlc Expect like library?

2018-02-13 Thread Stephen Feyrer
Hi Justin, That looks really cool. I'll take some time reading about it and see if I can do anything. Thank you. -- Kind regards, Stephen. On 13 February 2018 at 18:26, Justin Smith wrote: > I've long thought implementing something like TCL expect in Clojure would >

Re: create vector from other vector and indices

2018-02-13 Thread Tomasz Sulej
Or even simpler: (map v idx) On 13 February 2018 at 20:48, Tomasz Sulej wrote: > (map #(v %) idx) > > or > > (map (partial get v) idx)) > > On 13 February 2018 at 20:10, Andre Bieler > wrote: > >> Just started with clojure. >> Lets say I have two

Re: create vector from other vector and indices

2018-02-13 Thread Tomasz Sulej
(map #(v %) idx) or (map (partial get v) idx)) On 13 February 2018 at 20:10, Andre Bieler wrote: > Just started with clojure. > Lets say I have two vectors, v containing values and another vector idx > that contains the indices by which vector v should be ordered

create vector from other vector and indices

2018-02-13 Thread Andre Bieler
Just started with clojure. Lets say I have two vectors, v containing values and another vector idx that contains the indices by which vector v should be ordered (rather a new vector be created, ordered given by idx. (def v [10, 11, 12, 13]) (def idx [1 3 0 2]) ; goal is a new vector with

Re: tlc Expect like library?

2018-02-13 Thread Justin Smith
I've long thought implementing something like TCL expect in Clojure would be a fun project, as far as I know it hasn't been tried (though the google results are drowned out by the Expectations testing library so who knows...). If I were doing this from scratch I'd start with the Process and

tlc Expect like library?

2018-02-13 Thread Stephen Feyrer
Hi, I would like to ask, is there a Clojure version of the tlc expect library or an equivalent? Something to launch and control other applications. Specifically I want to control text based terminal application. Emulating the screen, moving the cursor around and firing character codes at it?