C++中while循环语句怎么限制次数?

来源:学生作业学帮网 编辑:学帮网 时间:2024/07/06 14:31:57

C++中while循环语句怎么限制次数?

while(条件){}即可
比如说我要它只能循环10次,则
int n=0;
while(n