Examveda

What is the output of the function complex()?

A. 0j

B. 0+0j

C. 0

D. Error

Answer: Option B

Solution (By Examveda Team)

The correct answer is Option B: 0+0j.
The complex() function in Python is used to create a complex number.
When no arguments are passed, it returns 0 as the real and imaginary parts, resulting in the complex number 0+0j.

This Question Belongs to Python Program >> Python Built In Functions

Join The Discussion

Related Questions on Python Built In Functions