Post Reply 
about the proot command output
10-06-2014, 04:23 PM
Post: #5
RE: about the proot command output
(10-06-2014 03:58 PM)parisse Wrote:  If you want to sort by real part first then imaginary part, you can try something like:
l:=[-2+i, -i, 2+i ,3-i ,5i];
sort(l,(a,b)->if re(a)!=re(b) then re(a)<re(b) else im(a)<im(b) end);

Great, thanks.
I was just reading about SORT with functions in your hprime.pdf, but did not think of this possibility.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: about the proot command output - Alberto Candel - 10-06-2014 04:23 PM



User(s) browsing this thread: 1 Guest(s)