exam questions

Exam 350-901 All Questions

View all questions & answers for the 350-901 exam

Exam 350-901 topic 1 question 172 discussion

Actual exam question from Cisco's 350-901
Question #: 172
Topic #: 1
[All 350-901 Questions]


Refer to the exhibit. A developer created the code, but it fails to execute.
Which code snippet helps to identify the issue?
A.

B.

C.

D.

Show Suggested Answer Hide Answer
Suggested Answer: C

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
wunderup
Highly Voted 2 years, 12 months ago
catch statement is wrong. correct answer is A.
upvoted 22 times
...
FR99
Highly Voted 2 years, 9 months ago
Answer is ‘A’. There is no ‘catch’ statement in Python language.
upvoted 8 times
...
Teringzooi
Most Recent 7 months, 3 weeks ago
Correct answer: A >>> read_file = open("me.txt", "r") Traceback (most recent call last): File "<stdin>", line 1, in <module> FileNotFoundError: [Errno 2] No such file or directory: 'me.txt'
upvoted 1 times
...
designated
9 months ago
A is correct.. there is no catch in python. try: # do something pass except ValueError: # handle ValueError exception pass
upvoted 2 times
...
ferock
1 year ago
A is correct the catch is not a statement in python
upvoted 1 times
...
kayleen
2 years, 5 months ago
A is less wrong than the others :)
upvoted 3 times
...
san111
2 years, 7 months ago
Agree with A >>> read_file = open("me.txt", "r") Traceback (most recent call last): File "<stdin>", line 1, in <module> FileNotFoundError: [Errno 2] No such file or directory: 'me.txt' >>>
upvoted 1 times
...
blezzzo
2 years, 8 months ago
I'll go with A too. The try block lets you test a block of code for errors. The except block lets you handle the error. The finally block lets you execute code, regardless of the result of the try- and except blocks. try: print(x) except: print("An exception occurred")
upvoted 3 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago