How to add method, or rename method name?
I have code like this:
"X Y".split().first => X
"X Y".split().last => Y
In a string, there is always only one space.
I'd like to change this to:
"X Y".a => X
"X Y".b => Y
How to achieve this goal? Ryby 2.7, Rails 6
Regards