Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Why didn't you show instead how to output arguments joined by a comma or some other separator instead of space.

The Tcl variant to output "comma" as separator (note -- this is not "CSV").

     puts [join $argv ,]
If you wanted "comma space" you'd do:

     puts [join $argv ", "]
If you actually wanted "CSV" then it would be (assuming tcllib is installed):

     package require csv
     puts [csv::join $argv]


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: