Home / CSE MCQs / Python MCQs :: Discussion

Discussion :: Python MCQs

  1. What is the value of x if:

    x = int(43.55+2/2)
  2. A.
    43
    B.
    44
    C.
    22
    D.
    23

    View Answer

    Workspace

    Answer : Option B

    Explanation :

    The expression shown above is an example of explicit conversion. It is evaluated as int(43.55+1) = int(44.55) = 44. Hence the result of this expression is 44.


Be The First To Comment