C++-字符串-选择你喜爱的水果
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
Background
Description
选择你喜爱的水果。程序中保存了7种水果的名字,要求用户输入一个与水果有关的句子。程序在已存储的水果名字中搜索,以判断句子中是否包含7种水果的名称。如果包含,则用词组” Pitayas”(火龙果)替换句子中出现的水果单词,并输出替换后的句子。如果句子中没有出现这些水果的名字,则输出”You must not enjoy fruit.”。假设7种水果的名字为:apples, bananas, peaches, cherries, pears, oranges, strawberries。
Format
Input
Output
Samples
I like apples.
I like Pitayas.
Limitation
1s, 1024KiB for each test case.
C++基础知识04(字符与字符数组、字符串)
- Status
- Done
- Rule
- ACM/ICPC
- Problem
- 11
- Start at
- 2024-5-5 17:00
- End at
- 2024-5-20 17:00
- Duration
- 360 hour(s)
- Host
- Partic.
- 7