Problem 1894 --Problem B: Soundex

1894: Problem B: Soundex

"
Time Limit $1$ 秒/Second(s) Memory Limit $512$ 兆字节/Megabyte(s)
提交总数 $2$ 正确数量 $2$
裁判形式 标准裁判/Standard Judge 我的状态 尚未尝试
难度 分类标签

Problem B: Soundex

Soundex coding groups together words that appear to sound alike based on their spelling. For example, "can" and "khawn", "con" and "gone" would be equivalent under Soundex coding.

Soundex coding involves translating each word into a series of digits in which each digit represents a letter:

      1 represents B, F, P, or V
      2 represents C, G, J, K, Q, S, X,  or Z
      3 represents D or T
      4 represents L
      5 represents M or N
      6 represents R

The letters A, E, I, O, U, H, W, and Y are not represented in Soundex coding, and repeated letters with the same code digit are represented by a single instance of that digit. Words with the same Soundex coding are considered equivalent.

Each line of input contains a single word, all upper case, less than 20 letters long. For each line of input, produce a line of output giving the Soundex code.

KHAWN
PFISTER
BOBBY
25
1236
11

推荐代码 查看1894 所有题解 上传题解视频得图灵币

本题记录 用 户(点击查看用户) 运行号(点击购买题解) 时 间
算法最快[$0 $ms] 淡意的温柔 588984 2020-05-30 10:32:52
内存最少[$944 $KB] AOJ大管家 84409 2017-04-27 15:28:38
第一AC AOJ大管家 84409 2017-04-27 15:28:38
第一挑战 AOJ大管家 84409 2017-04-27 15:28:38

赛题来源/所属竞赛 NA N/A

竞赛编号 竞赛名称 竞赛时间 访问比赛