base58> ( base58 -- seq )


Vocabulary
base58

Inputs
base58an object


Outputs
seqan object


Definition


:: base58> ( base58 -- seq )
BV{ } clone :> accum base58 alphabet first [ = not ] curry
find [ drop base58 length ] unless :> i 0 base58
[ [ 58 * ] dip base58>ch + ] i each-from
[ 256 /mod accum push ] until-zero i [ 0 accum push ] times
accum reverse! B{ } like ;