| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1445 人关注过本帖
标题:高精度
只看楼主 加入收藏
心剑菩提
Rank: 1
等 级:新手上路
帖 子:249
专家分:0
注 册:2007-5-17
收藏
 问题点数:0 回复次数:13 
高精度

Time Limit:1000MS Memory Limit:65536K
Total Submit:0 Accepted:0

Description

Problems involving the computation of exact values of very large magnitude and precision are common. For example, the computation of the national debt is a taxing experience for many computer systems.

This problem requires that you write a program to compute the exact value of Rn where R is a real number ( 0.0 < R < 99.999 ) and n is an integer such that 0 < n <= 25.


Input

The input will consist of a set of pairs of values for R and n. The R value will occupy columns 1 through 6, and the n value will be in columns 8 and 9.

Output

The output will consist of one line for each line of input giving the exact value of R^n. Leading zeros should be suppressed in the output. Insignificant trailing zeros must not be printed. Don't print the decimal point if the result is an integer.


Sample Input


95.123 12
0.4321 20
5.1234 15
6.7592 9
98.999 10
1.0100 12

Sample Output


548815620517731830194541.899025343415715973535967221869852721
.00000005148554641076956121994511276767154838481760200726351203835429763013462401
43992025569.928573701266488041146654993318703707511666295476720493953024
29448126.764121021618164430206909037173276672
90429072743629540498.107596019456651774561044010001
1.126825030131969720661201


Hint

If you don't know how to determine wheather encounted the end of input:
s is a string and n is an integer

Source

East Central North America 1988

搜索更多相关主题的帖子: 高精度 computation Limit exact magnitude 
2007-10-12 15:35
永夜的极光
Rank: 6Rank: 6
等 级:贵宾
威 望:27
帖 子:2721
专家分:1
注 册:2007-10-9
收藏
得分:0 

楼主你无不无聊啊,随便找个OJ网站,一道题目复制过来发个帖子


从BFS(Breadth First Study)到DFS(Depth First Study)
2007-10-12 15:56
我不是郭靖
Rank: 3Rank: 3
等 级:新手上路
威 望:6
帖 子:494
专家分:6
注 册:2006-10-4
收藏
得分:0 
把OJ 地址帖出来啊.

2007-10-12 16:10
kingkong6358
Rank: 1
等 级:新手上路
帖 子:148
专家分:0
注 册:2007-10-11
收藏
得分:0 
OJ是什么啊?

2007-10-12 16:12
我不是郭靖
Rank: 3Rank: 3
等 级:新手上路
威 望:6
帖 子:494
专家分:6
注 册:2006-10-4
收藏
得分:0 

Online Judge


2007-10-12 16:18
crackerwang
Rank: 3Rank: 3
等 级:新手上路
威 望:8
帖 子:833
专家分:0
注 册:2007-2-14
收藏
得分:0 

这个是PKU1001


2007-10-12 21:17
企鹅
Rank: 1
等 级:新手上路
帖 子:93
专家分:0
注 册:2006-7-14
收藏
得分:0 
。。还是字符串模拟吧
2007-10-12 21:24
心剑菩提
Rank: 1
等 级:新手上路
帖 子:249
专家分:0
注 册:2007-5-17
收藏
得分:0 

会做的请帮忙解决一下
希望大家帮忙 确实不会做 会做的都做了啊

[此贴子已经被作者于2007-10-16 8:04:02编辑过]


前世五百次的回眸 才换来今生的擦肩而过
2007-10-13 13:53
Galileo
Rank: 1
等 级:新手上路
帖 子:20
专家分:0
注 册:2007-10-10
收藏
得分:0 
以下是引用心剑菩提在2007-10-13 13:53:21的发言:

会做的请帮忙解决一下 不想做的请不要说:

楼主你无不无聊啊,随便找个OJ网站,一道题目复制过来发个帖子

什么叫无聊啊 我的作业题啊

希望大家帮忙 确实不会做 会做的都做了啊

既然问作业就要谦虚求教,不要这样人身攻击,否则删帖
用数组就可以解决您的问题,建立数组A,B存储数据,然后通过模拟四则运算来实现

2007-10-13 17:21
coachard
Rank: 3Rank: 3
等 级:新手上路
威 望:7
帖 子:1251
专家分:0
注 册:2007-8-12
收藏
得分:0 
可以参照雨中飞燕的高精度算法,虽然难道,但效率很高。。。

偶学编程,也许本身就是一个错。。。
2007-10-13 19:59
快速回复:高精度
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.028539 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved