856 B
856 B
id | title | challengeType | isHidden | isRequired | videoId |
---|---|---|---|---|---|
5e7b9f060b6c005b0e76f059 | More Conditional Structures | 11 | true | true | HdL82tAZR20 |
Description
Tests
question:
text: 'Given the following code:<pre>
1 |temp = "5 degrees"<br>
2 |cel = 0<br>
3 |try:<br>
4 | fahr = float(temp)<br>
5 | cel = (fahr - 32.0) * 5.0 / 9.0<br>
6 |except:<br>
7 | print("temp should be a number")<br>
8 |print(cel)<br>
</pre>
Which line would cause the script to immediately stop because of an error?'
answers:
- '1'
- '4'
- '6'
- '7'
- 'None'
solution: 2