![]() |
Comment |
PYTHON | Comment
- Comments are used for to explain the python code
- Comments are used for to make more readable
- Comments are not considered when running the program
there are two types of comments
1) single line comments
Single line comments start with a #
Example
# This is a comment
print("Hello, World")
` 2) Multi line Comments
Multi line comments write Between """ """ or ''' '''
Example
""" This is a comment
is ignored by python interpreter """
print("Hello, World")
or
Example
''' This is a comment
is ignored by python interpreter '''
print("Hello, World")