INOI1602 Brackets

As the statement did not state very clear, I would like to ask if a subseqeunce can be empty? (Not choosing any pairs at all)

Also what is the answer if there is no valid subseqeunces at all?

This is the problem https://www.codechef.com/IOIPRAC/problems/INOI1602

  1. Yes, a sub-sequence may be empty.
  2. There may be no valid sub-sequence at all.

In both the cases, the answer should be 0.

1 Like

A Link to Q will be appreciated ^^