How do I store Ruby standard outputs to multiple variables?
For example, if I have:
puts "hello"
puts "thanks"
How do I store "hello" and "thanks" to two different variables like strVar
(containing the value "hello") and strVar2
(containing the value "thanks").
In my script, I am calling another Ruby script which will puts
multiple strings to standard output. How do I store each string from the standard output individually?