6 kyu

#Paper and pencil: Figure out the value of letters by sum of words.

185 of 229LS2008

Description:

Story

In 22022, a disaster wiped out human beings. A team of alien archaeologists wanted to find out more about languages of human beings. However, when it comes to English, they only see letters with numbers. You are the leader of this group, with your master-alien-mind, you figured out the numbers mean the sum of words, now you just have to figure out the value of each number!


Task

Write a function with a string parameter, consisting of ONLY lowercase letters, and seperated by spaces. Use the test cases to figure out what each lowercase value represents, and return the sum of the words in list/tuple (depending on language). The letters represent values from 1-26.

Input

a string of words, seperated by spaces.

Output

A list/tuple representing the sum of words.

Example

"i am fine thank you" ---> [24, 32, 73, 61, 32]

Precondition

number of tests = 160
30<=number of words<=60
2<=length of words<=20

Notes

  • the alphabets' values are not in the alphabetical order.
  • any translations will be appreciated!
  • You can definitely solve the value of each word in example test cases, it's guaranteened.
  • Only try to solve this kata when you have at least 1 hour of time
Strings
Logic
Ciphers
Puzzles

Stats:

CreatedDec 17, 2022
PublishedDec 17, 2022
Warriors Trained560
Total Skips28
Total Code Submissions611
Total Times Completed229
Python Completions185
C Completions51
Total Stars13
% of votes with a positive feedback rating95% of 61
Total "Very Satisfied" Votes57
Total "Somewhat Satisfied" Votes2
Total "Not Satisfied" Votes2
Total Rank Assessments16
Average Assessed Rank
7 kyu
Highest Assessed Rank
6 kyu
Lowest Assessed Rank
8 kyu
Ad
Contributors
  • LS2008 Avatar
  • Blind4Basics Avatar
  • rowcased Avatar
Ad