develooper Front page | perl.perl6.users | Postings from January 2019

Re: I need m/ help

Thread Previous | Thread Next
From:
JJ Merelo
Date:
January 14, 2019 19:00
Subject:
Re: I need m/ help
Message ID:
CAJoLtgfNjPFyqfEKk0FUgo5a7eO6P5jerufcY54eetmYbb=8eQ@mail.gmail.com
El lun., 14 ene. 2019 a las 18:41, Brad Gilbert (<b2gills@gmail.com>)
escribió:

> Nl is not “*non-arabic numbers*” and it is not “*numbers that have a
> value by themselves*”.
> While both seem like correct statements, they are the wrong way to think
> about the Nl category.
> If either were entirely correct then there wouldn't be a need for No
> (Number other).
>
> *Nl (Number letter)* is for *“Numerals composed of letters or letterlike
> symbols (e.g., Roman numerals)”*
> (copied from
> https://en.wikipedia.org/wiki/Template:General_Category_(Unicode) )
>
> Note that Roman numerals also “*have a positional value*” and can “*be
> collated to other numbers to form bigger numbers*”.
>

No, they don't, at least not in Perl 6:

say ⅮⅭ
https://gist.github.com/Whateverable/14d4c361c81bc6e784c42a12ca83a6a0

You can try for any other Nl, it just does not. However:

    say Ⅾ+Ⅽ; OUTPUT: «600␤»

(because they have a numeric value by themselves).

Only those with the Nd property can be collated to form any kind of number;
these are in number system which are positional and decimal (at least those
I've tried):

    say ߁߃ # OUTPUT: «13␤»

(these are Nko digits)

Cheers

JJ

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About