How to write commen…
 
Notifications
Clear all

How to write comments in Python?

1 Posts
2 Users
0 Likes
178 Views
0
Topic starter

How to write comments in Python?

1 Answer
0
There are two common ways to comment out multiple lines in Python:
  1. Using consecutive single-line comments: Prefix each line with the hash symbol (#).
  2. Using multiline strings as comments: Enclose the code within triple quotes (either single or double quotes).
Share: