1.输入一行字符,统计其中有多少个单词,每两个单词之间以空格隔开。
如输入: This is a c++ program. 输出:There are 5 words in the line.
2.给出一个字符串,在程序中赋初值为一个句子,例如"he threw three free throws",
自编函数完成下面的功能:
1)求出字符列表中字符的个数(对于例句,输出为26)
3.给定一个字符串来代表一个学生的出勤纪录,这个纪录仅包含以下三个字符:
'A' : Absent,缺勤
'L' : Late,迟到
&