(c) s = qui * add / 4 - 6 / 2 + 2 / 3 * 6 / god ;
( qui = 4, add = 2, god = 2, assume sto be an int )
Answer
s = 4 * 2 / 4 - 6 / 2 +2 / 3 * 6 / 2 operation: *
s = 8 / 4 - 6 / 2 + 2 / 3 * 6 / 2 operation: /
s = 2 - 6 / 2 + 2 / 3 * 6 / 2 operation: /
s = 2 - 3 + 2 / 3 * 6 / 2 operation: /
s = 2 - 3 + 0 * 6 / 2 operation: *
s = 2 - 3 + 0 / 2 operation: /
s = 2 - 3 + 0 operation: -
s = - 1 + 0 operation: +
s = - 1
(d) s = 1 / 3 * a / 4 - 6 / 2 + 2 / 3 * 6 / g ;
( s = 4, g = 3 , assume to be an int )
Answer
s = 1 / 3 * 4 / 4 - 6 / 2 + 2 / 3 + 6 / 3 operation: /
s = 0 * 4 / 4 - 6 / 2 + 2 / 3 * 6 / 3 operation: *
s = 0 / 4 - 6 / 2 + 2 / 3 * 6 / 3 operation: /
s = 0 - 6 / 2 + 2 / 3 * 6 / 3 operation: /
s = 0 - 3 + 2 / 3 * 6 / 3 operation: /
s = 0 - 3 + 0 * 6 / 3 operation: *
s = 0 - 3 + 0 / 3 operation: /
s = 0 - 3 + 0 operation: -
s = - 3 + 0 operation: +
s = -3
( qui = 4, add = 2, god = 2, assume sto be an int )
Answer
s = 4 * 2 / 4 - 6 / 2 +2 / 3 * 6 / 2 operation: *
s = 8 / 4 - 6 / 2 + 2 / 3 * 6 / 2 operation: /
s = 2 - 6 / 2 + 2 / 3 * 6 / 2 operation: /
s = 2 - 3 + 2 / 3 * 6 / 2 operation: /
s = 2 - 3 + 0 * 6 / 2 operation: *
s = 2 - 3 + 0 / 2 operation: /
s = 2 - 3 + 0 operation: -
s = - 1 + 0 operation: +
s = - 1
(d) s = 1 / 3 * a / 4 - 6 / 2 + 2 / 3 * 6 / g ;
( s = 4, g = 3 , assume to be an int )
Answer
s = 1 / 3 * 4 / 4 - 6 / 2 + 2 / 3 + 6 / 3 operation: /
s = 0 * 4 / 4 - 6 / 2 + 2 / 3 * 6 / 3 operation: *
s = 0 / 4 - 6 / 2 + 2 / 3 * 6 / 3 operation: /
s = 0 - 6 / 2 + 2 / 3 * 6 / 3 operation: /
s = 0 - 3 + 2 / 3 * 6 / 3 operation: /
s = 0 - 3 + 0 * 6 / 3 operation: *
s = 0 - 3 + 0 / 3 operation: /
s = 0 - 3 + 0 operation: -
s = - 3 + 0 operation: +
s = -3
No comments:
Post a Comment