
高精度
ZeroLH00
这个作者很懒,什么都没留下…
展开
-
UVA 748-Exponentiation
UVA 748-Exponentiation题目大意:算含小数点的数的n次方解题思路:先把小数点去掉,然后大位数乘法#include <stdio.h> #include <string.h> #include <stdlib.h> #include <iostream> using namespace std; void mul(char* a, char* b) { int l1 = s原创 2016-07-26 21:10:49 · 347 阅读 · 0 评论 -
UVA 424-Integer Inquiry
UVA 424-Integer Inquiry题目大意:大位数加法解题思路:用字符数组装数,然后倒过来加#include <stdio.h> #include <string.h> #include <iostream> using namespace std; void add(char *a,char *b) { char c[1000]; char d[1000]; m原创 2016-07-19 19:36:05 · 335 阅读 · 0 评论 -
UVA 10106-Product
UVA 10106-Product题目大意:大位数乘法解题思路:用数组模拟#include <iostream> #include <stdio.h> #include <string.h> using namespace std; void mul(char* a, char* b) { int l1 = strlen(a); int l2 = strlen(b); int原创 2016-07-21 16:43:06 · 575 阅读 · 0 评论 -
UVA 465-Overflow
UVA 465-Overflow题目大意:与int型范围比较,判断第一个数,第二个数与结果是否太大解题思路:用atof存double进行比较输出#include <stdio.h> #include <iostream> #include <math.h> #define max 2147483647 using namespace std; int main() { char a[1000原创 2016-07-21 16:48:00 · 281 阅读 · 0 评论