Câu 110: PCEP-30-02: PCEP – Certified Entry-Level Python Programmer
You are coding a math utility by using Python. You are writing a function to compute roots. The function must meet the following requirements:• If a is non-negative, return a ** (1 / b)• If a is negative and even, return 'Result is an imaginary number'• If a is negaitve and odd, return -(-a) ** (1 / b)Which of the fol…
Nội dung câu hỏi
You are coding a math utility by using Python. You are writing a function to compute roots. The function must meet the following requirements:• If a is non-negative, return a ** (1 / b)• If a is negative and even, return 'Result is an imaginary number'• If a is negaitve and odd, return -(-a) ** (1 / b)Which of the following functions meets the requirements?
Các lựa chọn
Đáp án được giữ gọn theo nhãn A, B, C, D trong phần bình chọn tương tác.
-
A. Lựa chọn A bằng hình ảnh — đáp án hiện tại
-
B. Lựa chọn B bằng hình ảnh
-
C. Lựa chọn C bằng hình ảnh
-
D. Lựa chọn D bằng hình ảnh
Cộng đồng
0 bình luận công khai. Tên thành viên được ẩn một phần.