KAMIL - Kamil

no tags 

Some kids cannot pronounce all letters, some of them they sometimes pronounce correctly and sometimes incorrectly. Kamil sometimes says T instead of K, but he never says K instead of T. Similarly he sometimes says D instead of G. Instead of R he sometimes says L and sometimes F. Of course it happens that he pronounces the letter correctly. Kamil's father always thinks how many words can mean the word spoken by his son (it doesn't matter if they are real English words).

Task

Write a program which

  • reads from standard input the words spoken by Kamil
  • counts how many different words can that mean
  • writes the outcome on standard output

 

Input

Ten test cases (given one under another, you have to process all!). Every test case is a single line - a word spoken by Kamil. Only 26 capital leters are used. The length of the word is at most 20.

Output

For every testcase write an integer in a single line with a single integer, denoting the number of words which Kamil's word can mean.

Score

The score awarded to your program is the number of bytes the source code you submit. The fewer points you score, the better. Submissions are not allowed to exceed 256 bytes.

Remark. It may turn out impossible to solve this problem in some languages.

Example

Input:
FILIPEK
[and 9 test cases more]

Output:
4
[and 9 test cases more]


hide comments
venky_2801: 2017-05-26 17:56:18

181 C

likhith: 2017-04-29 07:30:35

i am getting a run time error(SIGSEGV).....can anyone help me..

mhto: 2017-03-06 19:03:20

131 bytes in c :D . Killed all the Whitespaces.

Last edit: 2017-03-07 15:04:19
dotjabber: 2017-02-02 15:09:59

244 java :)

hari123: 2016-11-22 17:11:27

square1001: 2016-07-30 05:45:27
106 bytes in C. gets function is very good. :-)
is bluffing, he didn't done this problem, if doubt see his profile

(reply from Min_25)
It is not bluffing. Challenge problems are not shown in user pages. And you can find his name in the ranking.

Last edit: 2016-11-22 20:15:01
karikjoshi21: 2016-10-18 14:48:20

151 in cpp

patafian: 2016-10-04 14:39:56

181 cpp

hacker_sk: 2016-10-02 17:28:13

182 in c++. :(

ddog: 2016-08-26 14:42:42

71 :) Python

contrapants: 2016-08-18 16:04:29

38 in Perl :-)


Added by:Adam Dzedzej
Date:2004-06-08
Time limit:3s
Source limit:256B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: NODEJS OBJC PERL6 SQLITE VB.NET
Resource:Internet Contest Pogromcy Algorytmow (Algorithm Tamers) Round I, 2003