comment

Text in a program after a # sign, which Python ignores and which exists only for human readers.

In more detail

Use comments to explain why code does something, not to repeat what it obviously does. Putting # in front of a line, commenting it out, is a quick way to switch it off while testing. Docstrings, not comments, document what a function does.

Related terms

Taught in

References

Certification courses