Certified Professional in Python Programming (PCPP-32-101) — Question 7

Select the true statements related to PEP 8 naming conventions. (Choose two.)

Answer options

Correct answer: A, B

Explanation

Option A is correct because PEP 8 specifies that function and variable names should be in lower-case with underscores. Option B is also correct as it emphasizes the use of 'self' and 'cls' as the first arguments for instance and class methods, respectively. Option C is incorrect because module names should be in all lower-case, not CamelCase. Option D is wrong since constants should be in all uppercase letters, not lower-case.