alias numconv { var %n $remove($token($1,1,32),$chr(44)),%r return,%o,%i,%1 onetwothreefourfivesixseveneightnineteneleventwelvethirfourfifsixseveneighnine,%3 0twenthirforfifsixseveneighnine,%4 thousandmbtrquadrquintsextseptoctnondecundecduodectredecquattuordecquindecsexdecseptendecoctodecnovemdecvigint if $regex(%n,[+-]) || (%n !isnum) %r $iif($len(%n),Invalid) if ($regex(%n,^0*(\.|$))) %r zero %n = $token(%n,1,46) if $len(%n) > 66 %r Invalid while %n { var %w $base($right(%n,3),10,10,3),%h $left(%w,1),%t $mid(%w,2,1),%u $mid(%w,3) %o = $iif(%h,$token(%1,%h,3) hundred) $iif(%t,$iif(%t = 1,$token(%1,$calc(10+%u),3) $+ $iif(%u > 2,teen),$token(%3,%t,3) $+ ty)) $+ $iif(%u && %t != 1,$iif(%t,-) $+ $token(%1,%u,3)) $iif(%i && %w != 0,$token(%4,%i,3) $+ $iif(%i > 1,illion)) %o inc %i $regsub(%n,.?.?.$,,%n) } %r %o }