ruby array of multiple type of value upcase only email code example
Example 1: capitalize composed name ruby
require 'active_support/core_ext'
"kirk douglas".titleize #=> "Kirk Douglas"
Example 2: capitalize composed name ruby
'one TWO three foUR'.gsub(/\w+/, &:capitalize)