Skip to content

Instantly share code, notes, and snippets.

@PJZ9n
Created February 5, 2021 22:34
Show Gist options
  • Save PJZ9n/90b11c2c29bc61aa2d81bb7fe68d3ec1 to your computer and use it in GitHub Desktop.
Save PJZ9n/90b11c2c29bc61aa2d81bb7fe68d3ec1 to your computer and use it in GitHub Desktop.
CSVから禁止ワードのリストを生成する http://monoroch.net/kinshi/kinshi.csv
require "csv"
words = []
CSV.foreach("test.csv") do |row|
words << row[0] unless row[0].nil?
words << row[1] unless row[1].nil?
words << row[2] unless row[2].nil?
end
puts words
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment