short

描述

short 是 16 位元的整数型别。

在 86Duino 上,short 变数可储存 16 位元的整数值,范围由 -32768 到 32767 (最小值 -2^15,最大值 (2^15) – 1)。

范例


short ledPin = 13;

语法


short var = val;

var short 变数名称
val 指派给变数的数值

See also

byte
int
unsigned int
long
unsigned long
Integer Constants
Variable Declaration


语法参考主页面

本页由热血青年 LBU 译自英文版。

The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.