Tap here to switch tabs
Problem
Submissions

Problem: Decrypt String from Alphabet to Integer Mapping

med
30 min
Try to solve the Decrypt String from Alphabet to Integer Mapping problem.

Statement

You are given a string s formed by digits and the character '#'. We want to map s to lowercase English characters as follows:

  • Characters from 'a' to 'i' are represented by ′1′'1' to ′9′'9' respectively.

  • Characters from 'j' to 'z' are represented by '10#' to '26#' respectively.

Return the string formed after mapping.

Constraints:

  • 1≤1 \leq s.length ≤1000\leq 1000

  • s consists of digits and the '#' character.

  • s is a valid string such that a mapping is always possible.

⋮
Tap here to switch tabs
Problem
Submissions

Problem: Decrypt String from Alphabet to Integer Mapping

med
30 min
Try to solve the Decrypt String from Alphabet to Integer Mapping problem.

Statement

You are given a string s formed by digits and the character '#'. We want to map s to lowercase English characters as follows:

  • Characters from 'a' to 'i' are represented by ′1′'1' to ′9′'9' respectively.

  • Characters from 'j' to 'z' are represented by '10#' to '26#' respectively.

Return the string formed after mapping.

Constraints:

  • 1≤1 \leq s.length ≤1000\leq 1000

  • s consists of digits and the '#' character.

  • s is a valid string such that a mapping is always possible.