KnowledgeBoat Logo
|

Computer Science

Assertion (A): Comments are non-executable statements that are ignored by the interpreter.

Reasoning (R): Comments are used to explain the code and to make it more informative for the users. They are basically statements used to put remarks.

  1. Both A and R are true and R is the correct explanation of A.
  2. Both A and R are true but R is not the correct explanation of A.
  3. A is true but R is false.
  4. A is false but R is true.

Python Funda

2 Likes

Answer

Both A and R are true and R is the correct explanation of A.

Explanation
Comments are non-executable statements in a script that are ignored by the Python interpreter and, therefore, have no effect on the actual output of the code. They are used to explain Python code and make it more readable and understandable for humans. Essentially, comments are used to include remarks within the code.

Answered By

1 Like


Related Questions