创建一个程序,打印其源在英语单词中的字符数量。
如果你的程序有九个字母长,它应该打印“九”。
大写化被忽略:如果您打印"one“(不知何故),您可以打印"oNe”、"one“、"ONE”或其他任何东西。
十基地是必需的。
适当的间距也是必要的。
在(不太可能,但只是为了说明)的情况下,您的程序达到10亿或更多字符,使用美国数字规模。十亿是10^9,一百万是10^6。
不要使用“101”:使用“一百零一”。
不要使用连字符。打印44,而不是44.
带有假程序的测试用例:
10.(96 0s later)..01 prints one HuNdreD ONE -- okay: proper spacing, no "and"
10.(96 0s later)..01 prints one HuNdreDONE -- not okay: wrong spacing
10.(96 0s later)..01 prints one thousand two hundred two -- not okay: base 3 rather than base 10
10...(999999996 0s later) prints nine hundred ninety-nine million nine hundred ninety-nine thousand nine hundred ninety-six: not okay, wrong number and includes hyphens黄金挑战,一如既往:最短代码获胜。不过,你可以在绿色滴答发出后自由发帖。这为难以编程的语言提供了更完整的服务。马尔博格有人吗?
发布于 2019-10-20 01:51:51
Type fourhundred chars? I say, I think I have an angle.
I say "Gosh, could I just go create some poem? Clearly it comes a long way, writing stuff I say."
I compose the entire written poem, and someone reads a tiny, tiny portion.
"Surely, it all is garbage," cried a big fat crybaby.
Would HE frankly notice how many long, tedious hours I took?
The crybaby whined a lot. I watched, then I ignored him.打印Four HunDrED。(我试图让它在300 s中打印一些数字,但我似乎不能在400字节以下打印。)
“诗意”是我在2018年为一个班级项目而做的一部作品。基本上是用字长而不是符号来思考。
发布于 2019-10-20 13:18:36
https://codegolf.stackexchange.com/questions/194480
复制相似问题