'Why print function in python does not print anything but debugging it do have something?

I need some help with python. I am debugging with my python program as the print function does not print anything in the console, but it does really have something in the debugger. Why does this happen?

Screen shot for debugging

The image above is the python debugging result, as there do really have something that is showing in tmp

enter image description here

But the print function does not work as it only produced the final output, instead of printing the tmp variable.

Why does this happen? Appreciate it a lot!



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source