#include<bits/stdc++.h>
using namespace std;
int main()
{
string anry[100];
int k=0;
string name;
while(name!=".")
{
getline(cin,name);
anry[k++]=name;
}
k=k-1;
if(k>=13)
{
cout<<anry[1]<<" and "<<anry[13]<<" are inviting you to dinner..."<<endl;
}
if(1<=k&&k<13)
{
cout<<anry[1]<<" is the only one for you..."<<endl;
}
if(0<=k<1)
{
cout<<"Momo... No one is for you ..."<<endl;
}
}
L1-035 情人节
最新推荐文章于 2024-10-16 19:20:14 发布
这篇文章展示了一个简单的C++程序,通过情人节场景模拟,使用字符串数组来判断并输出个性化的邀请信息。程序根据输入名字的数量决定不同的祝福语。
摘要由CSDN通过智能技术生成