C-16-Q071mediumsingle_mcq
After w = float("4.2"), the value of w is:
After w = float("4.2"), the value of w is:
- a4
- b'4.2'
- c4.2
- d42
ব্যাখ্যা
float() parses the string "4.2" as a decimal number, producing the float 4.2. The quotation marks are stripped during conversion, so the result is a numeric float value, not a string.