zsh-users
 help / color / mirror / code / Atom feed
* How to impose a numeric sort on negative numbers?
@ 2020-07-01 17:45 Sebastian Gniazdowski
  2020-07-01 18:02 ` Mikael Magnusson
  2020-07-01 18:48 ` Lawrence Velázquez
  0 siblings, 2 replies; 18+ messages in thread
From: Sebastian Gniazdowski @ 2020-07-01 17:45 UTC (permalink / raw)
  To: Zsh Users

[-- Attachment #1: Type: text/plain, Size: 252 bytes --]

Hi,
arr=( -1A -2b -3B 0 1A 2C 3B )
print -rl ${(on)arr}

Output:
0
1A
-1A
-2b
2C
3B
-3B

So it's not "correct". How to sort from -3 to 2?
-- 
Sebastian Gniazdowski
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zinit
Blog: http://zdharma.org

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2020-07-07 16:19 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-01 17:45 How to impose a numeric sort on negative numbers? Sebastian Gniazdowski
2020-07-01 18:02 ` Mikael Magnusson
2020-07-01 18:07   ` Sebastian Gniazdowski
2020-07-01 18:12     ` Roman Perepelitsa
2020-07-03 18:12     ` Lewis Butler
2020-07-03 18:35       ` Bart Schaefer
2020-07-01 19:42   ` Peter Stephenson
2020-07-02 11:36     ` Daniel Shahaf
2020-07-02 12:00       ` Peter Stephenson
2020-07-03 16:21         ` Hyphens, minuses, and dashes (was: Re: How to impose a numeric sort on negative numbers?) Daniel Shahaf
2020-07-02 15:46       ` How to impose a numeric sort on negative numbers? Bart Schaefer
2020-07-03 20:08         ` Peter Stephenson
2020-07-03 20:15           ` Bart Schaefer
2020-07-03 22:23           ` Daniel Shahaf
2020-07-07 16:14             ` Daniel Shahaf
2020-07-07 16:18               ` Daniel Shahaf
2020-07-01 18:48 ` Lawrence Velázquez
2020-07-06  7:15   ` Sebastian Gniazdowski

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).