I have a list of names (names.txt
) separated by line. After I loop through each line, I'd like to move it to another file (processed.txt
).
My current implementation to loop through each line:
open("names.txt") do |csv|
csv.each_line do |line|
url = line.split("\n")
puts url
# Remove line from this file amd move it to processed.txt
end
end