Valid Parentheses

Given a string s made up only of the bracket characters ()[]{}, return true if the brackets are closed correctly, otherwise return false.

A string is valid when both of these conditions hold:

  1. Every opening bracket is closed by a closing bracket of the same type.
  2. Brackets are closed in the correct order, so every closing bracket matches the most recent unmatched opening bracket.
Examples
Input: "()"
Output: true
Hints

Valid Parentheses

Given a string `s` made up only of the bracket characters `()[]{}`, return `true` if the brackets are closed correctly, otherwise return `false`.