the code where I properly calculated everything, 241 (speed, speed...):
Code:

Function BTA($b,$)
dim $c
if $
$c=bta($b,0)+bta($,0)
$=729
while $
$b=1-2*($c<0)
$b=$b*($b*2*$c>$)
$c=$c-$b*$
if $bta | $b | $=1 $bta=$bta+""+$b endif
$=$/3
loop
else
$=1
while $b
$c=0>right($b,2)
$bta=$bta-2*$*$c+$*right($b,1)
$b=left($b,-1-$c)
$=$*3
loop
endif
EndFunction



Edited by Jooel (2005-02-23 10:36 AM)
_________________________
!

download KiXnet