High_precision_calculation

所属分类:数值算法/人工智能
开发工具:C/C++
文件大小:176KB
下载次数:7
上传日期:2010-06-27 16:12:59
上 传 者wuzele
说明:  对数值很大、精度很高的数进行高精度计算是一类十分常见的问题。比如,对国债进行计算就是属于这类问题。现在要你解决的问题是:对一个实数R( 0.0 < R < 99.999 ),要求写程序精确计算 R 的 n 次方(Rn),其中n 是整数并且 0 < n <= 25。Input:T输入包括多组 R 和 n。 R 的值占第 1 到第 6 列,n 的值占第 8 和第 9 列。Output:对于每组输入,要求输出一行,该行包含精确的 R 的 n 次方。输出需要去掉前导的 0 后不要的 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.)

文件列表:
rrr\Debug\rrr.exe (176209, 2010-06-27)
rrr\Debug\rrr.ilk (192624, 2010-06-27)
rrr\Debug\rrr.obj (4474, 2010-06-27)
rrr\Debug\rrr.pch (203644, 2010-06-27)
rrr\Debug\rrr.pdb (443392, 2010-06-27)
rrr\Debug\StdAfx.obj (2018, 2010-06-27)
rrr\Debug\vc60.idb (41984, 2010-06-27)
rrr\Debug\vc60.pdb (53248, 2010-06-27)
rrr\rrr.cpp (1306, 2010-06-27)
rrr\rrr.dsp (4500, 2010-06-25)
rrr\rrr.dsw (514, 2010-06-25)
rrr\rrr.ncb (41984, 2010-06-27)
rrr\rrr.opt (49664, 2010-06-27)
rrr\rrr.plg (1293, 2010-06-27)
rrr\StdAfx.cpp (290, 2010-06-25)
rrr\StdAfx.h (769, 2010-06-25)
rrr\Debug (0, 2010-06-27)
rrr (0, 2010-06-27)

======================================================================== CONSOLE APPLICATION : rrr ======================================================================== AppWizard has created this rrr application for you. This file contains a summary of what you will find in each of the files that make up your rrr application. rrr.dsp This file (the project file) contains information at the project level and is used to build a single project or subproject. Other users can share the project (.dsp) file, but they should export the makefiles locally. rrr.cpp This is the main application source file. ///////////////////////////////////////////////////////////////////////////// Other standard files: StdAfx.h, StdAfx.cpp These files are used to build a precompiled header (PCH) file named rrr.pch and a precompiled types file named StdAfx.obj. ///////////////////////////////////////////////////////////////////////////// Other notes: AppWizard uses "TODO:" to indicate parts of the source code you should add to or customize. /////////////////////////////////////////////////////////////////////////////

近期下载者

相关文件


收藏者