3

Perhaps in any browser or any environment such as NodeJS? The closest I can get to is:

console.log((10000).toLocaleString("zh-u-nu-hanidec"))
"一〇,〇〇〇"

inside of Chrome or Firefox. (The result being looked for is 一萬 or 一万, with the first form traditional Chinese character, and the second form simplified Chinese character). I am not sure what the u is for zh-u, maybe it is for unicode and it needs to put in front of nu for number system. Also I wonder why it has to be this form but

(10000).toLocaleString("zh", {numberingSystem: "hanidec"})

would give "10,000".

The first line output really is just converting 1 to , which is just a one to one mapping of digit characters. The way 10000 is spoken or written should be 一萬 or 一万. There is a 10000 unit. So for 1000, it is 一千, meaning "One(一) Thousand(千)", but for 10000, it is not written or spoken as "Ten Thousand" but as "One(一) Wàn(萬)", with Wàn meaning 10,000.

I read into MDN and ECMA-402 but can't find the relevant info yet.

Matt Johnson-Pint
  • 230,703
  • 74
  • 448
  • 575
nonopolarity
  • 146,324
  • 131
  • 460
  • 740
  • Is an ajax request from a page like https://lexisrex.com/Chinesisch-Zahlen/10000 an option? Mabe a own table would make it even more portable? – Lauber Bernhard Jan 20 '20 at 20:15

0 Answers0