fruit = ["apple","red","banana","yellow"]
=> ["apple", "red", "banana", "yellow"]
Hash[*fruit]
=> {"apple"=>"red", "banana"=>"yellow"}
Why does the splat cause the array to be so neatly parsed into the Hash?
Or, more precisely, how does the Hash "know" that "apple" is the key and "red" is its corresponding value?
Is it simply because they are at consecutive positions in the fruit array?
Does it matter that the splat is used here? Can a Hash not define itself from an arry so directly otherwise?