2.3

Note: In the answers the question is in black, the rough work is in red in the order it is done and the final answer is in blue.

  1. i = 3 j = 2 k = 5
    1. i++; i = 4
      j = --k; k = 4 so j = 4
      i = 4 j = 4 k = 4
    2. ++j; j = 3
      k = i++ + --j; j = 2, k = 3 + 2 = 5, i = 4
      i = 4 j = 2 k = 5
    3. j = ++i * i++; i = 4, j = 4 * 4 = 16, i = 5
      i = 5 j = 16 k = 5
    4. k = i++ / j--; k = 3 / 2 = 1, i = 4, j = 1
      i = 4 j = 1 k = 1
    5. i = ++k * j--;k = 6, i = 6 * 2 = 12, j = 1
      i = 12 j = 1 k = 6
    6. k = (2 + i++) / (3 + ++j);j = 3, k = (2 + 3)/(3 + 3) = 5 / 6 = 0, i = 4
      i = 4 j = 3 k = 0
  2. i = 0 j = 3
    1. i = ++j + j; j = 4, i = 4 + 4 = 8
      i = 8 j = 4
    2. i = j + j++; i = 3 + 3 = 6, j = 4
      i = 6 j = 4
    3. i = ++j * 2 + ++j * 3; j = 4 then 5, i = 4 * 2 + 5 * 3 = 8 + 15 = 23
      i = 23 j = 5
    4. i = ++j * 3 + ++j * 2; j = 4 then 5, i = 4 * 3 + 5 * 2 = 12 + 10 = 22
      i = 22 j = 5
    5. j = 3  * j-- + 2 * j--; first use j's current value (3) and then subtract 1 so now it is 2
      use that for the second j in the equation
      so j = 3 * 3 + 2 * 2, j becomes 2 and then 1 temporarily but from the calculation j = 9 + 4 = 13
      i = 0 j = 13
    6. j = 2 * j-- + 3 * --j; j = 2 * 3 + 3 * 1, j temporarily becomes 1
      but from the calculation j = 6 + 3 = 9
      i = 0 j = 9
    1. y = ++x - z++;
    2. z = ++x * y - 1;
    1. m = n - p;
      n++;
      p--:
    2. ++n;
      p = n - m;
      m--;
  3. j = 0;
    k = 0;
    j = --j; j becomes -1 temporarily because pre-increment and then that -1 is stored so j = -1
    k = k++; we will store the current value of k (0) eventually in k but first we have to temporarily add 1 to it
    because of the post-increment so it becomes 1 before we store the 0 to replace that value.
    j = -1 k = 0