Ural 1001. Reverse Root(没有输入结束的坑爹题)
发布日期:2021-11-06 16:56:40 浏览次数:5 分类:技术文章

本文共 828 字,大约阅读时间需要 2 分钟。

1001. Reverse Root

Time limit: 2.0 second
Memory limit: 64 MB
The problem is so easy, that the authors were lazy to write a statement for it!

Input

The input stream contains a set of integer numbers 
Ai (0 ≤ 
Ai ≤ 10
18). The numbers are separated by any number of spaces and line breaks. A size of the input stream does not exceed 256 KB.

Output

For each number 
Ai from the last one till the first one you should output its square root. Each square root should be printed in a separate line with at least four digits after decimal point.

Sample

input output
1427 
0   876652098643267843 5276538
2297.0716936297014.11640.000037.7757
AC代码:
#include 
#include
double a[300000],p;int main(){ int i=0,n; while(scanf("%lf",&p)!=EOF)//没有输入结束的标志 a[i++]=sqrt(p); for(n=i-1;n>=0;n--) printf("%.4lf\n",a[n]); return 0;}

转载地址:https://blog.csdn.net/YJX_xx/article/details/37654777 如侵犯您的版权,请留言回复原文章的地址,我们会给您删除此文章,给您带来不便请您谅解!

上一篇:Wow! Such Doge!(同样没有输入结束标志的坑题)
下一篇:edward_mj退役经验帖(浙大final队员-陈伟杰)

发表评论

最新留言

表示我来过!
[***.240.166.169]2024年04月01日 17时08分56秒