When a value is truncated to 3 decimal places, which of the following is true?
Anonymous Quiz
15%
Both positive and negative numbers are rounded down.
31%
Positive numbers are rounded down and negative numbers are rounded up.
31%
Positive numbers are rounded up and negative numbers are rounded down.
22%
Both positive and negative numbers are rounded up.
Code snippet:
A = [[1, 2, 3],
[4, 5, 6],
[7, 8, 9]]
[A[i][i] for i in range(len(A))]
What will be the output of the code?
Anonymous Quiz
65%
[1, 5, 9]
16%
[3, 5, 7]
8%
[4, 5, 6]
12%
[2, 5, 8]
What will be the output of the code?
Anonymous Quiz
29%
__str__ called
24%
__repr__ called
19%
Error
28%
Nothing is printed
What will be the output of the Python code?
Anonymous Quiz
25%
0 1 2
39%
0 1 2 0 1 2 0 1 2 โฆ
24%
None None None
12%
None of the mentioned
What will be the output of the Python code?
Anonymous Quiz
10%
6
12%
12
50%
24
19%
Error
9%
None of the mentioned
๐1