+=
名称
+=
説明
ある変数にある数値を足した結果を、元の変数に再度代入する際に利用できる便利な省略形である。
書式
x += y; // equivalent to the expression x = x + y;
引数
| x | 任意の変数。利用可能な型: int, float, double, byte, short。long。 |
| y | 任意の変数もしくは定数。利用可能な型: int, float, double, byte, short, long。 |
使用例
|
|
参照
オリジナルのページ
https://docs.arduino.cc/language-reference/en/structure/compound-operators/compoundAddition/
最終更新日
July 22, 2026