Evaluated proc asc2hb_pair twolines { set lines [nlsplit $twolines]; set sizes [cgetsize $twolines]; set l1 [first $lines]; set l2 [second $lines]; set out ""; for {set x 0} {$x < [first $sizes]} {incr x} {set f [second [cgetchar $twolines $x 0]]; set b [second [cgetchar $twolines $x 1]]; if {[string is digit $f$b] == 1} { append out [chb $f $b] } elseif {[sid $f] == 1 || [sid $b] == 1} { append out [chb $f $f] } }; . $out }