RosettaCodeData/Task/CSV-data-manipulation/Tcl/csv-data-manipulation-2.tcl
2026-02-01 16:33:20 -08:00

6 lines
135 B
Tcl

set f [open example.csv r]
puts "[gets $f],SUM"
while { [gets $f row] > 0 } {
puts "$row,[expr [string map {, +} $row]]"
}
close $f