The link to question is -
https://online.codingblocks.com/app/player/96041/content/73549/4801/code-challenge
The link to code is –
All my test cases are coming wrong. Please tell the error.
The link to question is -
https://online.codingblocks.com/app/player/96041/content/73549/4801/code-challenge
The link to code is –
All my test cases are coming wrong. Please tell the error.
The first thing immediately noticeable is that you are directly printing booleans in Python. This is problematic because when printing booleans, Python prints “True” or “False”. The expected output is “true” or “false”. Notice the case mismatch. Also, flag_d is a redundant variable, removing it will have no impact on the logic.
Hope this helps!