Isolating search terms from a URL in Ruby
===

I have an array of ugly, complex URL strings and I want to separate out specific search terms that people have typed such as "example" from `http://google.com/search/things/q="example"`.

Occasionally there is a search that has a `+` separating terms and at the end of the user-specified query is a `&`. 

I have no idea where to start, even after plenty of Googling around. Any help to get me started would be greatly appreciated!