Make use of a qualified tutor to get the answer
ar.map(&:reverse)
Ruby is python but with slightly different syntax
ar.map { |element| element.reverse }
Ruby is a dynamic, open source programming language with a focus on simplicity and productivity