加照片的c++爱心❤代码
时间: 2023-10-16 12:27:14 浏览: 111
以下是一个简单的 C++ 爱心代码,它使用了 ASCII 图形来绘制一个基本的爱心形状:
```c++
#include <iostream>
using namespace std;
int main()
{
cout << "\n\n\t\t\t\t\t";
cout << "*************" << endl;
cout << "\t\t\t\t";
cout << "***************" << endl;
cout << "\t\t\t\t";
cout << "*****************" << endl;
cout << "\t\t\t\t";
cout << "*******************" << endl;
cout << "\t\t\t\t";
cout << "********************" << endl;
cout << "\t\t\t\t";
cout << "*******************" << endl;
cout << "\t\t\t\t";
cout << "*****************" << endl;
cout << "\t\t\t\t";
cout << "***************" << endl;
cout << "\t\t\t\t";
cout << "*************" << endl;
cout << "\t\t\t\t\t";
cout << "*** ***" << endl;
cout << "\t\t\t\t\t ";
cout << "*** ***" << endl;
cout << "\t\t\t\t\t ";
cout << "*** ***" << endl;
cout << "\t\t\t\t\t ";
cout << "*****" << endl;
cout << "\t\t\t\t\t ";
cout << "***" << endl;
cout << "\t\t\t\t\t ";
cout << "***" << endl;
cout << "\t\t\t\t\t ";
cout << "***" << endl;
cout << "\t\t\t\t\t ";
cout << "***" << endl;
return 0;
}
```
输出结果:
```
*************
***************
*****************
*******************
********************
*******************
*****************
***************
*************
*** ***
*** ***
*** ***
*****
***
***
***
***
```
阅读全文