Back
Close
  • 47

Learning Opportunities

This puzzle can be solved using the following concepts. Practice using these concepts and improve your skills.

Statement

 Goal

Given N integers, print their English cardinal forms. For example, 525600 is spelled "five hundred twenty-five thousand six hundred".

Note: no "and", no commas, and hyphens to separate composite cardinals such as "forty-two".
Input
First line: N, the number of integers to "translate" into English
Next N lines: the integers, Xi..
Output
N lines of English cardinals
Constraints
-2^64Xi < 2^64 (~18 quintillion)
Example
Input
1
525600
Output
five hundred twenty-five thousand six hundred

A higher resolution is required to access the IDE

codingame x discord
Join the CodinGame community on Discord to chat about puzzle contributions, challenges, streams, blog articles - all that good stuff!
JOIN US ON DISCORD
Online Participants