搜索资源列表
计算分数的精确值
- 使用数组精确计算M/N(0<M<N<=100)的值。如果M/N是无限循环小数,则计算并输出它的第一循环节,同时要求输出 循环节的起止位置(小数位的序号) *问题分析与算法设计 由于计算机字长的限制,常规的浮点运算都有精度限制,为了得到高精度的计算结果,就必须自行设计实现方法。 为了实现高精度的计算,可将商存放在一维数组中,数组的每个元素存放一位十进制数,即商的第一位存放在第一个元素中,商的第二位存放在第二个元素中....,依次类推。这样就可以使用数组不表示一个高
feizhenshu
- 非整数分频器 分频系数为无限不循环小数 vhdl-non-integer frequency divider coefficient of circulator is not unlimited vhdl
CHANGE1
- 无限循环小数转换成分数 无限循环小数转换成分数-unlimited repeater converted into scores unlimited repeater converted into scores
分数转循环小数
- 分数转循环小数,JAVA编写
xunhuan
- 给定一个分式A/D,A为分子,D为分母,将分式化解成最简形式,例如1/3 = 0.[3],化成循环小数形式,并用[]将循环节提取出来-To a fraction A/D, A for the molecule, D is the denominator, will dissolve into the simplest fractional form, such as 1/3 = 0. [3], into a recurring decimal form, and [] will be extra
xunhuan0924
- 给定一个分式A/D,A为分子,D为分母,将分式化解成最简形式,例如1/3 = 0.[3],化成循环小数形式,并用[]将循环节提取出来,这个是优化的程序,可以计算出10^9长度的循环节-To a fraction A/D, A for the molecule, D is the denominator, the fraction into simplest form of resolve, such as 1/3 = 0. [3], into a recurring decimal form,
Circulation
- 判断PI在有限位的情况下是否是循环小数-PI is a recurring decimal to determine whether
fenshu_xiaoshu
- 通过简单的算法和较合理的数据结构,将所有的分数可以转化成小数。包括循环小数!-This program uses simple data ,and it works well
1
- 随机性算法。通过模拟投点法,计算无限不循环小数Pi的值,并比较投掷不同次数时值的精确程度。-Random algorithm. Through the simulation stage investment, calculate the value of Pi unlimited non-recurring decimal, and to compare the number of a time when throwing different degree of precision.
jiaocuofenpin
- 用硬件语言写了一个由8/9分频构成的无限不循环小数分频器,分频系数k=260/31-Written language with the hardware a 8/9 frequency divider consisting of an infinite non-recurring decimal, frequency factor k = 260/31
RecurDecimalPro
- 将分数转化为小数,对徐无限循环小数,能够给出循环节显示,如1/6表示为0.1(6)等-Will be converted to decimal points, infinitely recurring decimal for Xu, able to give a circular section shows, such as 1/6 is expressed as 0.1 (6), etc.
Displayed-as-a-decimal-fraction
- 分数显示为小数,例如3/4=0.75.1/3=0.333,还有循环小数的表示方法,自己看算法-Scores as fractions, such as 3/4 = 0.75.1/3 = 0.333, as well as recurring decimal representation, their algorithm to see
275
- 每输入一行包括两个整形数A和B(A<B),A为分子,B为分母。 Task1.判断是否为有限小数。 Task2.若为循环小数,求出循环小数部分并输出。 -Each input line contains two integers A and B (A <B),A为分子,B为分母。 Task1.判断是否为有限小数。 Task2.若为循环小数,求出循环小数部分并输出。
xiaoshu
- 是一个用C语言编写的求解循环小数的循环节的程序-Is a solution written in C language section of the program loop circulator
exchange
- 任何小数都可以被划为分数,但是循环小数的实现和一般的有所区别,本程序主要实现的功能是如何实现将普通小数和循环小数转化为都准化为最简分数。-Any decimal can be classified as a fraction, but the recurring decimal to implement and in general different, the main achievement of the function of this program is how to achieve
OJ
- 2897:英文缩写词 给定一个由若干英文单词组成的字符串,生成一个由各首字母组成的缩写词(acronym),其中的the,a,an,of,for及and被忽略。 2895: 循环小数 给定一个分数,判断其是否是一个无限循环小数,并输出它的第一个循环节 2531: 乘船 春暖花开,实验室集体去长风公园泛舟。 实验室有n(1<=N<=2000)个人,每个人重量为ci.长风公园的每艘船的载重量为K,每次最多乘两人。假设每个人只能坐一次船,那么至
solve
- 蓝桥试题 循环小数表示 单函数解决问题 简洁-Blue Bridge questions Recurring decimals said
circulatingdecinmal
- 求循环小数循环节,效率较高,有较少的时间复杂度和空间复杂度。-get the reptend of one circulating decimals
cycle
- 输入两个不大于100000的正整数a和b,输出a/b的结果。当然,不是只输出整数部分,小数部分也是要算出来的,不过因为是整数, 如果结果是无限小数,结果一定是循环小数,必定存在循环节,比如1/3 = 0.33333....,或者1/7 = 0.142857142857..., 所以如果是循环小数,那么仅仅输出到第一个循环节结束就可以了,如果不是循环小数,则把精确结果输出(多余的末尾0不要输出)。 输入 仅一行输入,包含两个整数a和b,中间以空格分开-Not more than 1
用链表求循环小数
- 对于任意的真分数 N/M ( 0 < N < M ),均可以求出对应的小数。如果采用链表表示各个小数,对于循环节采用循环链表表示,则所有分数均可以表示为如下链表形式。 输入: N M 输出: 转换后的小数(不超过 50 位) 要求: 仅编写将分数转换为小数的函数 change( int n, int m, NODE * head ) 。 预设代码: /* PRESET CODE BEGIN - NEVER TOUCH CODE BELOW */ #in