空き時間にサクッと
problem
解いた
# @param {Integer[]} nums # @param {Integer} n # @return {Integer[]} def shuffle(nums, n) first = nums[0...n] second = nums[n..] result = [] (2 * n).times do |i| if i.even? result << first.shift else result << second.shift end end result end