建筑人才网官方网站查询,网站用视频做背景,济宁最新通知今天,学校网页网站模板文章目录 复合数据类型数组 复合数据类型
数组
数据类型 数组名[元素个数]
#includeiostreamusing namespace std;int main()
{const int n 3;// 元素个数必须为常量double ls[n];//初始化int ls1[2] {1, 2};float ls2[] {1.2, 3.1, 5.2, 6.6};short ls3[5] {3,… 文章目录 复合数据类型数组 复合数据类型
数组
数据类型 数组名[元素个数]
#includeiostreamusing namespace std;int main()
{const int n 3;// 元素个数必须为常量double ls[n];//初始化int ls1[2] {1, 2};float ls2[] {1.2, 3.1, 5.2, 6.6};short ls3[5] {3, 6, 9}; // 其他值为0// 不能超不能用数组给数组赋值
}