Problem Description

"Open close open open open close open open open close open open...?"

"Close."

"Close open close close close open close close open close close...?"

"Open."

Implementation

You should submit a file that implements the following procedure:

string openorclose(int N, string *Q)
N: The number of words.
Q: N words, "open" or "close".
Returns: The answer, "open" or "close".