Matt Kettler wrote:
Really in regexes there is no such thing as an AND operation. It's just not something natural to do in a regex.
I would argue, at a deeper level of language/grammar theory, that this isn't true. Instead, AND is implied by concatenation. "X.*Y.*Z" says "X and Y and Z all have to be present". The catch is that an order is implied by the concatenation, where we don't always assume an order to AND and OR operators in other contexts (and the | operator in regex's doesn't impose order, the way concatenation does).
Which leads to:
So in the first chunk, John faked an And. What you really have is two expressions that are ORed together.
The thing that I ORed was the order of the elements, not the ANDing of elements. The ANDing of the elements is a natural consequence of the concatenation. The first chunk says "maintain and clouds". The second chunk says "clouds and mountain".