Solved Write A Function Isvalid That Given A String S

Solved Write A Function Isvalid That Given A String S