Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Feature: Represents k-adic notation A.K.A. Bijective numeration
- 엑셀 등의 스프레드시트 프로그램은 열(column)을 표시하기 위해서 알파벳을 사용합니다.
- 열 번호가 주어질 때, 거기에 해당하는 알파벳으로 된 열 이름을 구하는 프로그램을 작성하세요.
- Scenario Outline: k-adic notation [A-WIKIPEDIA]
- Given I have the number <number>
- When I represent its k-adic notation
- Then I see the notation <result>
- Examples:
- | number | result |
- | 0 | |
- | 1 | A |
- | 2 | B |
- | 3 | C |
- | 4 | D |
- | 26 | Z |
- | 27 | AA |
- | 28 | AB |
- | 52 | AZ |
- | 53 | BA |
- | 25*26 + 26 | YZ |
- | 26*26 + 26 | ZZ |
- | 26**2 + 26 + 1 | AAA |
- | 26**2 + 26 + 2 | AAB |
- | 26**2 + 2*26 + 3 | ABC |
- | 4878821185187 | WIKIPEDIA |
Add Comment
Please, Sign In to add comment