JRS: In article <c6************@ID-99375.news.uni-berlin.de>, seen in
news:comp.lang.javascript, Ian Richardson <za*****@chaos.org.uk> posted
at Sat, 24 Apr 2004 20:17:30 :
At the moment I'm using a quicksort algorithm to sort a list of
countries in alphabetic order. This worked wonderfully until someone
came up with the Åland Islands... and this is at the end of the list.
I'm not sure it's supposed to be.
Now I could just alter my comparison so it ignores the top bit, but this
would then put it at the top of the list, even before Albania...
Alternatively, should I put Å after A?
In short, is there a preferred way of ordering these?
I don't think those Islands *are* a country, but ICBW; are they not
loose bits of Finland - or are they a country in the same sense as Wales
& Scotland are? I have enough difficulty in determining which parts of
the globe are in the EU, or associated, or whatever, for
<URL:http://www.merlyn.demon.co.uk/european.htm>.
However, while Å may well sort to the end of the alphabet in all
languages that use it, that does not necessarily mean that all letters
of the extended Roman Alphabet sort to identical positions in all
countries that use them. It is possible that Potaniland sorts Æ
between A & B, while Erewhon puts it at the end.
I think all likely extended-roman letters can be mapped in an obvious
manner to one or two English letters; it is probably best to use that,
then sort. After all, even foreigners will probably not know the proper
sort order for languages other than their own; but they will be used to
what the Anglos do with their names. My fair-sized atlas indexes those
Islands as "Aland", in the middle of the "A" section.
Remember that the proper names of Asian and North African countries need
transliteration to be readable by the average Anglo - and may be quite
different too : one does not necessarily seek Bharat or Nippon among the
B or N sections.
<URL:http://www.merlyn.demon.co.uk/quotes.htm#FredHoyle> :-)
--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
<URL:http://jibbering.com/faq/> Jim Ley's FAQ for news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.