Excel Column Name

Spreadsheet columns use letters instead of numbers: after Z comes AA, then AB, and so on. Given a positive integer columnNumber, return the matching Excel-style column title. For example, 1 becomes A and 28 becomes AB.

Примеры

Ввод
1
Вывод
"A"
Ввод
28
Вывод
"AB"
Ввод
701
Вывод
"ZY"

Нужно реализовать

def convert_to_title(columnNumber: int) -> str:

Теги

mathstrings
PostgreSQLv16

Ovdje će se prikazati rezultat izvršavanja koda

Visible tests
1
Input
1
Expected"A"
2
Input
28
Expected"AB"
3
Input
701
Expected"ZY"
4
Input
26
Expected"Z"
5
Input
702
Expected"ZZ"
6
Input
-100
Expected""
Focus radio
Paused · SomaFM · Fluid