标签: c variables variable-assignment
如何以不同的方式表达变量赋值(例如x = x * 3)?
x = x * 3
答案 0 :(得分:0)
这是另一种方式:
x *= 3;
同样,
x += 3; // it is the same as x = x + 3; x -= 3; // it is the same as x = x - 3; x /= 3; // it is the same as x = x/3;