数组;静态初始化数组;动态数组化数组

image

image

 

 

 

image

image

 

 

 

image

 

image

image

 

 

 

遍历数组:一个一个的访问容器中的数据

image

 

案例:

某部门5员工的销售额分别是:16,26,36,6,100。请计算出他们部门的总销售额

image

 

 

 

image

 

 

image

image

 

 

 案例

某歌唱比赛需开发一个系统:可以录入6名评委打分,录完后立即输出评委打分的平均分

image

 

image

 

posted @ 2026-06-02 16:28  白了过去  阅读(4)  评论(0)    收藏  举报