nerdexam
Python_Institute

PCPP-32-101 · Question #43

What is the result of the following code?

The correct answer is A. Nothing will be displayed. The default logging level is Warning. Info and Debug level is lower than Warning, therefore, no message for Info and Debug. If you try code, nothing shows up. Level name Value WARNING (Default) 30 https://edube.org/learn/pcpp1-5/logging-in-python-2

PEP and Best Practices

Question

What is the result of the following code?

Exhibit

PCPP-32-101 question #43 exhibit

Options

  • ANothing will be displayed
  • BLoading data...
  • CDebugging mode has been enabled
  • DDebugging mode has been enabled -

How the community answered

(51 responses)
  • A
    78% (40)
  • B
    12% (6)
  • C
    6% (3)
  • D
    4% (2)

Explanation

The default logging level is Warning. Info and Debug level is lower than Warning, therefore, no message for Info and Debug. If you try code, nothing shows up. Level name Value WARNING (Default) 30 https://edube.org/learn/pcpp1-5/logging-in-python-2

Topics

#debugging#logging#conditional output#code tracing

Community Discussion

No community discussion yet for this question.

Full PCPP-32-101 Practice