Re: tons of digits

2022-06-10 Thread Bruce Gray
> On Jun 10, 2022, at 8:01 AM, ToddAndMargo via perl6-users > wrote: > > Hi All, > I forgot how to write out a ton of digits for the square root of 2 (or any > other irrational number). Hi Todd, I suspect that this message is what you have misplaced: https://www.nntp.perl.org/group

Re: Easier way to load a buffer?

2022-06-10 Thread Elizabeth Mattijsen
> On 10 Jun 2022, at 23:28, ToddAndMargo via perl6-users > wrote: > >>> On Fri, 10 Jun 2022 at 15:49, ToddAndMargo via perl6-users >>> mailto:perl6-us...@perl.org>> wrote: >>>Hi All, >>>I am looking for an easier way to load a buffer. >>>I know about this way >>>[4] > my Buf

Re: Easier way to load a buffer?

2022-06-10 Thread ToddAndMargo via perl6-users
On Fri, 10 Jun 2022 at 15:49, ToddAndMargo via perl6-users mailto:perl6-us...@perl.org>> wrote: Hi All, I am looking for an easier way to load a buffer. I know about this way [4] > my Buf $b=Buf.new(0x2A, 0x54, 0xFF, 0x53); Buf:0x<2A 54 FF 53> I would like to do it on

Re: Easier way to load a buffer?

2022-06-10 Thread Elizabeth Mattijsen
> On 10 Jun 2022, at 22:47, ToddAndMargo via perl6-users > wrote: > >>> On Fri, 10 Jun 2022 at 15:49, ToddAndMargo via perl6-users >>> mailto:perl6-us...@perl.org>> wrote: >>>Hi All, >>>I am looking for an easier way to load a buffer. >>>I know about this way >>>[4] > my Buf

Re: Easier way to load a buffer?

2022-06-10 Thread ToddAndMargo via perl6-users
On Fri, 10 Jun 2022 at 15:49, ToddAndMargo via perl6-users mailto:perl6-us...@perl.org>> wrote: Hi All, I am looking for an easier way to load a buffer. I know about this way [4] > my Buf $b=Buf.new(0x2A, 0x54, 0xFF, 0x53); Buf:0x<2A 54 FF 53> I would like to do it on

Re: Easier way to load a buffer?

2022-06-10 Thread Simon Proctor
So Buf is expecting a list of integers. If' you've got one long one in a string like "2A54FF53A5F1D36F1CEA7E61FC37A20D54A77FE7B78" you want to split it into smaller values so something like this? my $hex = "2A54FF53A5F1D36F1CEA7E61FC37A20D54A77FE7B78"; my Buf $b=Buf.new(comb(2).map( *.parse-base(1

Easier way to load a buffer?

2022-06-10 Thread ToddAndMargo via perl6-users
Hi All, I am looking for an easier way to load a buffer. I know about this way [4] > my Buf $b=Buf.new(0x2A, 0x54, 0xFF, 0x53); Buf:0x<2A 54 FF 53> I would like to do it on one big blast: my Buf $b=Buf.new(0x2A54FF53A5F1D36F1CEA7E61FC37A20D54A77FE7B78); Cannot unbox 170 bit wide bigint into n

tons of digits

2022-06-10 Thread ToddAndMargo via perl6-users
Hi All, I forgot how to write out a ton of digits for the square root of 2 (or any other irrational number). -T -- ~~ Computers are like air conditioners. They malfunction when you open windows ~~

Re: Dual Buf and Str question

2022-06-10 Thread ToddAndMargo via perl6-users
On 6/10/22 02:36, Elizabeth Mattijsen wrote: On 10 Jun 2022, at 11:20, ToddAndMargo via perl6-users wrote: On 10 Jun 2022, at 07:54, ToddAndMargo via perl6-users wrote: Hi All, I can easily get away with this in Modula2, but how can I do this with Raku? I wish to create a single variabl

Re: Dual Buf and Str question

2022-06-10 Thread Elizabeth Mattijsen
> On 10 Jun 2022, at 11:20, ToddAndMargo via perl6-users > wrote: > >>> On 10 Jun 2022, at 07:54, ToddAndMargo via perl6-users >>> wrote: >>> >>> Hi All, >>> >>> I can easily get away with this in Modula2, but >>> how can I do this with Raku? >>> >>> I wish to create a single variable that

Re: Dual Buf and Str question

2022-06-10 Thread ToddAndMargo via perl6-users
On 10 Jun 2022, at 07:54, ToddAndMargo via perl6-users wrote: Hi All, I can easily get away with this in Modula2, but how can I do this with Raku? I wish to create a single variable that can be manipulated in two ways: 1) as a fixed length string (Str) 2) as a fixed length buffer (Buf) I

Re: Dual Buf and Str question

2022-06-10 Thread Elizabeth Mattijsen
Perhaps https://raku.land/zef:raku-community-modules/Pythonic::Str is what you're after? > On 10 Jun 2022, at 07:54, ToddAndMargo via perl6-users > wrote: > > Hi All, > > I can easily get away with this in Modula2, but > how can I do this with Raku? > > I wish to create a single variable th