Numbers to Letters
EasyP3Coding
Each number in nums is between 1 and 26. Map 1 to a, 2 to b, and so on up to 26 to z, and return the letters joined into one string in input order.
Example 1
- Input
- nums = [1,2,3,26]
- Output
- "abcz"
Example 2
- Input
- nums = []
- Output
- ""
Example 3
- Input
- nums = [1]
- Output
- "a"
Constraints
- 0 <= nums.length <= 10^5
- 1 <= nums[i] <= 26
Hints
Give it a real attempt first. Run shows which examples fail.
Saved automatically
Run checks the 3 visible tests, Submit all 10. ⌘Enter runs, ⌘⇧Enter submits.