Wildcard pattern matching

5 test cases are not getting passed with the code given below…
link https://ide.codingblocks.com/s/208537

@dakshi,
Updated Code Link, here

Hey @dakshi
How can I help you ?

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.