ExamGecko
Question list
Search
Search

Question 68 - 200-901 discussion

Report
Export

In Python, which expression checks whether the script returns a success status code when the Requests library is used?

A.

response.status_code == requests.codes.ok

Answers
A.

response.status_code == requests.codes.ok

B.

response.code == requests.codes.ok

Answers
B.

response.code == requests.codes.ok

C.

response.status_code == requests.ok

Answers
C.

response.status_code == requests.ok

D.

response.status_code != requests.codes.ok

Answers
D.

response.status_code != requests.codes.ok

Suggested answer: A

Explanation:


Reference: https://realpython.com/python-requests/

asked 07/10/2024
Talal Elemam
51 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first