RYIP在线题库
首 页   >   习题练习   >   提交
Problem1128--水仙花数

1128: 水仙花数

[Creator : ]
Time Limit : 1.000 sec  Memory Limit : 128 MB

【 Description 】

    所谓水仙花数就是一个三位数,其各位数字的三次幂(方)和等于其本身。
输入一个自然数 n ,输出不超过 n 的所有水仙花数。
    如果没有就输出 0,如果有多个,从小到大,两两之间用一个空格分隔。

【 Input 】

一个正整数 n(不超过1000)。

【 Output 】

按题目要求输出。

【 Sample Input 】

200

【 Sample Output 】

153

【 Source/Category 】