Python for Data Science: Chapter 1: Basics of Python

Python: Comments

Comments are the kind of statements that are written in the program for program understanding purposes.

Comments

•  Comments are the kind of statements that are written in the program for program understanding purposes.

•  By the comment statements it is possible to understand what exactly the program is doing.

•  In Python, we use the hash (#) symbol to start writing a comment.

•  It extends up to the newline character.

•  Python interpreter ignores comment.

•  For example ‒

# This is comment line

print("I love my country")

• If we have comments that extend multiple lines, one way of doing it is to use hash (#) in the beginning of each line. For example ‒

#This is

#another example

#of comment statement

 

Python for Data Science: Chapter 1: Basics of Python : Tag: Computer Programming, Python, Data Science : - Python: Comments


Python for Data Science: Chapter 1: Basics of Python



Under Subject


Python for Data Science

AD25201 2nd Semester AIDS Dept | 2025 Regulation | 2nd Semester 2025 Regulation



Related Subjects


English Essentials II

EN25C02 2nd Semester | 2025 Regulation | 2nd Semester 2025 Regulation



Linear Algebra

MA25C02 2nd Semester | 2025 Regulation


Applied Physics (CSIE) II

PH25C03 2nd Semester AIDS, CSE, IT, CSE(CY) Dept | 2025 Regulation | 2nd Semester 2025 Regulation


Digital Principles and Computer Organization

CS25C06 2nd Semester AIDS, CSE, IT, CSE(CY) Dept | 2025 Regulation | 2nd Semester 2025 Regulation


Basic Electrical and Electronics Engineering

EE25C01 2nd Semester | 2025 Regulation | 2nd Semester 2025 Regulation


Python for Data Science

AD25201 2nd Semester AIDS Dept | 2025 Regulation | 2nd Semester 2025 Regulation


Re-Engineering for Innovation

ME25C05 2nd Semester | 2025 Regulation | 2nd Semester 2025 Regulation


Python for Data Science - Laboratory

AD25201 2nd Semester AIDS Dept | 2025 Regulation | 2nd Semester 2025 Regulation