Indentation is very important when you are writing Python code. In Python, indentation defines the scope of your variables.
You are returning count
inside for
loop. Please correct that. You can try copying and pasting from the answer in left.
1 Like