golfathon/pund
2024-05-31 16:45:16 -05:00
..
a.py Initial commit 2024-05-31 16:45:16 -05:00
README.md Initial commit 2024-05-31 16:45:16 -05:00

pund

Define pund numbers as positive integers that look the same when rotated 180 degrees. 212 and 6699 are pund numbers while 17071 is not. More specifically 0, 1, 2, 5, and 8 are defined to be unchanged by a 180 degree rotation, while 6 after the rotation becomes a 9 and vice versa.

Your task is to write a program that takes in a positive integer k as an input and outputs the kth pund number.