Evaluated proc map2ascii mmap {array set ymap $mmap; foreach line [array get $ymap] { array set bmap $line; foreach part $bmap { append out "[lindex $part 5],[lindex $part 3][lindex $part 1]" }; append out "\n" };. $out }