21726_LETTERS

2022-5-16 18:20| 发布者: Hocassian| 查看: 24| 评论: 0|原作者: 肇庆学院ACM合集

摘要:
C:\Users\Administrator\Downloads\2019-10-12-10-14-4-89505794809200-Problem List-采集的数据-后羿采集器.html

Pro.ID

21726

Title

LETTERS

Title链接

http://10.20.2.8/oj/exercise/problem?problem_id=21726

AC

2

Submit

2

Ratio

100.00%

时间&空间限制

  • Time Limit: 1000/500 MS (Java/Others)     Memory Limit: 65536/65536 K (Java/Others)
  • 描述

    "The quick brown fox jumped over the lazy dogs."

    This sentence is well known for containing at least one of every letter of the alphabet. We could say, then, that it contains 26 different letters.

    In this problem you are given a series of pieces of text. In each case, state how many different letters the text contains. Spaces, digits and punctuation are ignored. Upper case letters are not distinguished from their lower case counterparts, so 'A' and 'a' just count as one letter.

    输入

    Input consists of a series of lines of text, each one no more than 250 characters long. Each piece of text will contain at least one non-white space character, but not necessarily a letter. The last line will contain just # - this line should not be processed.

    输出

    Description

    "The quick brown fox jumped over the lazy dogs."

    This sentence is well known for containing at least one of every letter of the alphabet. We could say, then, that it contains 26 different letters.

    In this problem you are given a series of pieces of text. In each case, state how many different letters the text contains. Spaces, digits and punctuation are ignored. Upper case letters are not distinguished from their lower case counterparts, so 'A' and 'a' just count as one letter.

    Input

    Input consists of a series of lines of text, each one no more than 250 characters long. Each piece of text will contain at least one non-white space character, but not necessarily a letter. The last line will contain just # - this line should not be processed.

    Output

    Output will consists of a single integer for each line of input, each integer on a line by itself. The integer will be the number of different letters found in the text.

    Sample Input

    The quick brown fox jumped over the lazy dogs.
    2 + 2 = 4
    New Zealand Programming Contest.
    #

    Sample Output

    26
    0
    16

    Source

    样例输入

    The quick brown fox jumped over the lazy dogs.
    2 + 2 = 4
    New Zealand Programming Contest.
    #

    样例输出

    26
    0
    16

    作者


    路过

    雷人

    握手

    鲜花

    鸡蛋

    最新评论

    返回顶部