MCQ Answer

<p>What will be the output of the following ?</p><pre><span style="font-size: 14px;">import math<br></span><span style="font-size: 14px;">print(math.fact(5))</span></pre>

What will be the output of the following ?

import math
print(math.fact(5))


निम्नलिखित कोड का आउटपुट क्या होगा?

import math
print(math.fact(5))
Topic : Operators Expressions and Python Statements

A. 120

B. 25

C. 1,2,3,4,5

D. Error




Correct Answer is :

D. Error



Explanation

this code will generate AttributeError: module 'math' has no attribute 'fact'

because there is no any fact() function in math module

CCC Online Test 2021 CCC Practice Test Hindi Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level Online Test in Hindi Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Sarkari Naukari Notification Best Website and Software Company in Allahabad Sarkari Exam Quiz