f0205.cpp
资源名称:c.rar [点击查看]
上传用户:puke2000
上传日期:2022-07-25
资源大小:912k
文件大小:0k
源码类别:
C#编程
开发平台:
Visual C++
- //=====================================
- // f0205.cpp
- // 字符倒三角形
- //=====================================
- #include<iostream>
- using namespace std;
- //-------------------------------------
- int main(){
- for(int i=1; i<=10; ++i){
- for(int j=1; j<=i-1; ++j)
- cout<<" ";
- for(int k=1; k<=21-2*i; ++k)
- cout<<"M";
- cout<<endl;
- }
- }//====================================