unknown
1970-01-01 00:00:00 UTC
--047d7bea40ba9bfe4f04eca04735
Content-Type: text/html; charset=windows-1252
Content-Transfer-Encoding: quoted-printable <div dir="ltr">>?<span style="font-family:arial,sans-serif;font-size:13px">You can create a simple linked list using a cons cell:</span><div><br></div><div>@John : Right, but you will always have quadratic complexity in length creating the sequence?<span style="font-family:arial,sans-serif;font-size:13px">$seq</span>.</div> <div><br></div><div>><span style="font-family:arial,sans-serif;font-size:13px">I can only speculate, because we haven?t seen your implementation, but</span></div><div><span style="font-family:arial,sans-serif;font-size:13px">> I am wondering why you didn?t take advantage of John?s existing></span></div> <div><span style="font-family:arial,sans-serif;font-size:13px">> $lessthan function argument in order to compare all kinds of items?</span></div><div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div> <div><span style="font-family:arial,sans-serif;font-size:13px">@ Christian. Indeed, I realized after profiling my rewriting of John code that its code implementation has also a quadratic complexity in sequence length. John, as I, need at a point to allocate memory for writing this tree implementation. If we want to stay pure xquery, this will be done with quadratic complexity in length, at least I can't see any work around to that.</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">>?</span><span style="font-family:arial,sans-serif;font-size:13px">It takes *time* to get into?</span><span style="font-family:arial,sans-serif;font-size:13px">the functional way of thinking</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">@Christian. I agree, this is another way of thinking, and I am surely not experienced with it, since I started a month ago. But I have here a basic problem, and I think that there is no answer : I don't know how to work with a stack or a vector with xquery. It means that?</span><span style="font-family:arial,sans-serif;font-size:13px">I will have to bind xquery to JAVA if I need to work extensively with these data structures.</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">>�</span><span style="font-family:arial,sans-serif;font-size:13px">that it?s possible to build efficient�</span><span style="font-family:arial,sans-serif;font-size:13px">data structures with functional languages</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">@Christian. Yes it is. So we are back to my previous question : why these data structures are not shipped as standard XQUERY for vectors or stacks handling, as maps are ?</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><br></div> </div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/12/3 John Snelson <span dir="ltr"><<a href="mailto:***@marklogic.com" target="_blank">***@marklogic.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On 03/12/13 11:27, jean-marc Mercier wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
> XQuery comes from the world of database<br>
I understand this point.
Content-Type: text/html; charset=windows-1252
Content-Transfer-Encoding: quoted-printable <div dir="ltr">>?<span style="font-family:arial,sans-serif;font-size:13px">You can create a simple linked list using a cons cell:</span><div><br></div><div>@John : Right, but you will always have quadratic complexity in length creating the sequence?<span style="font-family:arial,sans-serif;font-size:13px">$seq</span>.</div> <div><br></div><div>><span style="font-family:arial,sans-serif;font-size:13px">I can only speculate, because we haven?t seen your implementation, but</span></div><div><span style="font-family:arial,sans-serif;font-size:13px">> I am wondering why you didn?t take advantage of John?s existing></span></div> <div><span style="font-family:arial,sans-serif;font-size:13px">> $lessthan function argument in order to compare all kinds of items?</span></div><div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div> <div><span style="font-family:arial,sans-serif;font-size:13px">@ Christian. Indeed, I realized after profiling my rewriting of John code that its code implementation has also a quadratic complexity in sequence length. John, as I, need at a point to allocate memory for writing this tree implementation. If we want to stay pure xquery, this will be done with quadratic complexity in length, at least I can't see any work around to that.</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">>?</span><span style="font-family:arial,sans-serif;font-size:13px">It takes *time* to get into?</span><span style="font-family:arial,sans-serif;font-size:13px">the functional way of thinking</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">@Christian. I agree, this is another way of thinking, and I am surely not experienced with it, since I started a month ago. But I have here a basic problem, and I think that there is no answer : I don't know how to work with a stack or a vector with xquery. It means that?</span><span style="font-family:arial,sans-serif;font-size:13px">I will have to bind xquery to JAVA if I need to work extensively with these data structures.</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">>�</span><span style="font-family:arial,sans-serif;font-size:13px">that it?s possible to build efficient�</span><span style="font-family:arial,sans-serif;font-size:13px">data structures with functional languages</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">@Christian. Yes it is. So we are back to my previous question : why these data structures are not shipped as standard XQUERY for vectors or stacks handling, as maps are ?</span></div> <div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><br></div> </div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/12/3 John Snelson <span dir="ltr"><<a href="mailto:***@marklogic.com" target="_blank">***@marklogic.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On 03/12/13 11:27, jean-marc Mercier wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
> XQuery comes from the world of database<br>
I understand this point.