Max Alekseyev on Thu, 27 Sep 2007 23:12:17 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Pari get digit method?


On 9/27/07, Karim Belabas <Karim.Belabas@math.u-bordeaux1.fr> wrote:

>   \\ coeff of 10^k
>   kth_digit(n, k) = (n \ 10^k) % 10

All digits as a vector:

eval(Vec(Str(n)))

E.g.:

? eval(Vec(Str(723964)))
%1 = [7, 2, 3, 9, 6, 4]

Regards,
Max