Piece of code not working as it should

Can someone pls help me out with this.
The piece of code highlighted is where I am facing the problem because in the video it works perfectly but when I’m trying it out for myself it just wont work.
So if someone can pls help me it’ll be really great.

Hi @1804197,

  1. Can you share the code (copy-paste the code inside ``` instead of sharing the screenshot )
  2. Please share the screenshot of the output.
  3. Screenshot of the expected output

It will help us in resolving your query.