in reply to Re: Re: Re: Converting an array of bytes into a BigInt - speed considerations
in thread Converting an array of bytes into a BigInt - speed considerations
Yeah, well I solved it like this:
sub bigint_to_bytearray { my $bigint = shift; my @bytes; while(1) { push(@bytes,($bigint & 255)); $bigint->brsft(8); last if $bigint == 0; } return @bytes; }
--
dempa
|
|---|