我想使用下面的代码创建一个日期数组
arr = [] for i in (1..31) do arr << Date.new(2014, 9, i) end
我收到"无效日期"错误.有办法解决这个问题吗?
ruby
ruby ×1