[edit] extend: Forwardable è¦ç´ ãã®ã¯ã©ã¹ã¯ CSV ãã¡ã¤ã«ããã¼ã¿ã«å¯¾ããå®å ¨ãªã¤ã³ã¿ã¼ãã§ã¤ã¹ãæä¾ãã¾ãã èªã¿è¾¼ã¿ require "csv" csv_text = <<~CSV_TEXT Ruby,1995 Rust,2010 CSV_TEXT IO.write "sample.csv", csv_text # ãã¡ã¤ã«ããä¸è¡ã㤠CSV.foreach("sample.csv") do |row| p row end # => ["Ruby", "1995"] # ["Rust", "2010"] # ãã¡ã¤ã«ããä¸åº¦ã« p CSV.read("sample.csv") # => [["Ruby", "1995"], ["Rust", "2010"]] # æååããä¸è¡ã㤠CSV.parse(csv_text) do |row| p row
{{#tags}}- {{label}}
{{/tags}}