Missing module docstring (missing-module-docstring)

Viewed 1497

I am running below addition of two numbers in jupyter

''' This program summationoftwonumbers and displays their results '''

A = 1

B = 5

print('Sum of Numbers:',A+B)

it is running fine giving an output as "Sum of Numbers: 6"

But when running file byusing Pylint summationoftwonumber.ipynb

it is giving below errors

summationoftwonumbers.ipynb:1:0: C0114: Missing module docstring (missing-module-docstring) summationoftwonumbers.ipynb:1:0: W0104: Statement seems to have no effect (pointless-statement)

i am not understanding why these are coming

Any body help me out on this

1 Answers

It's that you used quotes to write a comment, which in some cases creates a docstring. Python is warning you that the statement has no effect in your program. To get rid of the warning you could rewrite the line:

''' This program summationoftwonumbers and displays their results '''

as a normal comment:

# This program summationoftwonumbers and displays their results 
Related