split string into 2 characters with condition ruby code example
Example: how to split string into characters ruby
string = "hey there"
string.chars #=> ["h", "e", "y", " ", "t", "h", "e", "r", "e"]
#OR
string.split("")
string = "hey there"
string.chars #=> ["h", "e", "y", " ", "t", "h", "e", "r", "e"]
#OR
string.split("")