import string


class Solution:
    def titleToNumber(self, s: str) -> int:
        store = {
            letter: index + 1
            for index, letter in enumerate(string.ascii_uppercase)
        }

        s = s[::-1]
        result = 0

        for index, letter in enumerate(s):
            power = 26 ** index if index else 1
            result += store[letter] * power

        return result

fd2b5d776ddb4b661afefb19fdd1abcf85bd9fc5
<mask token>

<mask token>


class Solution:
    <mask token>

<mask token>


class Solution:

    def titleToNumber(self, s: str) ->int:
        store = {letter: (index + 1) for index, letter in enumerate(string.
            ascii_uppercase)}
        s = s[::-1]
        result = 0
        for index, letter in enumerate(s):
            power = 26 ** index if index else 1
            result += store[letter] * power
        return result

import string


class Solution:

    def titleToNumber(self, s: str) ->int:
        store = {letter: (index + 1) for index, letter in enumerate(string.
            ascii_uppercase)}
        s = s[::-1]
        result = 0
        for index, letter in enumerate(s):
            power = 26 ** index if index else 1
            result += store[letter] * power
        return result

import string


class Solution:
    def titleToNumber(self, s: str) -> int:
        store = {
            letter: index + 1
            for index, letter in enumerate(string.ascii_uppercase)
        }

        s = s[::-1]
        result = 0

        for index, letter in enumerate(s):
            power = 26 ** index if index else 1
            result += store[letter] * power

        return result
