I can't figure out how to write an array vertically down a column to my output CSV file. Writing an array horizontally is simple enough and can be done in one line:
CSV.open("log.csv", "wb") do |csv|
csv << ["Computers",]
csv << myarray
end
Is there any way to get myarray written down a column in one line, or is it more complicated than that?
Array format:
["pc_0", "pc_1","pc_2"]
MyArray?MyArray) and what you expect the output CSV to look like.csv << MyArraywithMyArray.each { |e| csv << e }. BTW, an array starting with a captial letter looks strange in Ruby.