← Microsoft questions

Valid Parenthesis with Wildcard

Filed under Microsoft

Given a string s containing only '(', ')' and '*', determine if s is valid. '*' can be treated as a left parenthesis '(', a right parenthesis ')', or an empty string "". A string is valid if open…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Microsoft questions

Collected from public candidate posts and coding forums. Updated Nov 2026.