August 17, 2024
Python Comment
If you want to write some notes in your Python code file which you do not want to be execute in Python but want to include in your Python code file for better understanding your code. So for it you can create comments in Python. These comments present in your file but, these all will be ignored by the Python parser. There are two types of comments in Python, single line comment and multi line comment. You can start single line Python comments with # sign and you can write your text following that. And multi line Python comment starts with ''' and ends with '''. Examples of Python comments are mentioned below:
Single Line Comment
# comment sample
Multi line Comment
'''
comment sample line 1
comment sample line 2
'''