CSV data manipulation: Difference between revisions

CSV data manipulation en Yabasic
(CSV data manipulation en Yabasic)
Line 4,568:
4,8,12,16,20,60
</pre>
 
 
=={{header|Yabasic}}==
{{trans|FreeBASIC}}
<lang yabasic>open #1, "manipy.csv", "r" //existing CSV file separated by spaces, not commas
open #2, "manip2.csv", "w" //new CSV file for writing changed data
 
line input #1 header$
header$ = header$ + ",SUM"
print #2 header$
 
while !eof(1)
input #1 c1, c2, c3, c4, c5
sum = c1 + c2 + c3 + c4 + c5
print #2 c1, c2, c3, c4, c5, sum
wend
 
close #1
close #2
end</lang>
 
 
=={{header|zkl}}==
2,122

edits