Evaluate the expression given below if A = 30 and B=15.
A % B + A // B
Answers
Answered by
1
Answer:
2
Explanation:
A % B + A // B will be equivalent to 30%15 + 30//15
The priorities of operators in python are as followed:
- ()
- ^ or * *
- /, // , %, *
- +,-
Using that,
we solve it in the following order:
- 30%15 + 30//15
- 0+2
- 2
Similar questions