Create ValidParentheses.java

Give one optional solution to match parentheses