Converting Hexadecimal in Binary

Wouter wouter.abraham at pi.be
Sun Jan 11 05:45:08 EST 2004


On 11 Jan 2004, at 02:26, use-revolution-request at lists.runrev.com wrote:

>
> Message: 7
> Date: Sat, 10 Jan 2004 17:08:02 -0800 (PST)
> From: Alejandro Tejada <capellan2000 at yahoo.com>
> Subject: Re: Converting Hexadecimal in Binary
> To: use-revolution at lists.runrev.com
> Message-ID: <20040111010802.54537.qmail at web40507.mail.yahoo.com>
> Content-Type: text/plain; charset=us-ascii
>
> on Sat, 10 Jan 2004 11:24:00 -0700
> Dar Scott wrote
>
>> This might be faster yet:
>>
>> repeat with i = 1 to length(asd) step 6
>>     put null & binaryEncode("H*", char i to i+5 of
>> asd) after qwe
>> end repeat
>
> This is 400% faster than original!!!!!!!!!!
>
> So, putting the function inline cut the time
> in half. Excellent!
>
> Look at the three handlers working in this
> stack:
>
snip

On my slower rig it this is a little faster:

repeat with i = 1 to length(asd) step 6
     put 00 & char i to i+5 of asd after qwd
end repeat
put  binaryEncode("H*",qwd) into qwe

Greetings,
WA





More information about the use-livecode mailing list