However I did a test of:
Expand|Select|Wrap|Line Numbers
- two('y', 'z')
This is my code so far:
Expand|Select|Wrap|Line Numbers
- def chartonum(ch):
- return ord(ch) - 97
- def numtochar(n):
- return chr(n + 97)
- def two(c1 , c2):
- c1 = chartonum(c1)
- c2 = chartonum(c2)
- return numtochar(c1 + c2 %26)
EDIT: SOLVED.
Line 10 error in precedence. so ((c1 + c1)%26)