0

i have an array like this

text_arr = ["hello","how","are","you"]

and i want to convert this to string like this

text = "hello how are you"

How can i do this with Ruby ?

watermelon
  • 23
  • 5

1 Answers1

3

Try this one

text = text_arr.join(' ')
Ursus
  • 28,330
  • 3
  • 28
  • 45