摘要:
进制 给定一个正整数数对 N1,N2,并给出其中一个数字的进制,请你求出另一个数字在什么进制下,两数相等成立。 思路 约定字符串 a 是已知进制,b 是未知进制数; 二分枚举进制:一个数 b 如果是 k 进制,那么 b 的数字组成中必定不包含大于 k 的数字;所以二分的左边界可确定;右边界则是选一个 阅读全文
摘要:
you are supposed to find the largest continue sum, together with the first and the last numbers of the maximum subsequence. 方程:f[i]=max(f[i-1]+A[i], A 阅读全文
摘要:
A+B for Polynomials #include<bits/stdc++.h> using namespace std; const int N=2005; double A[N],B[N],C[N];//C为结果数组 //同指数,指数不变,系数相加,即C[i]+=A[i]+B[i] int 阅读全文
摘要:
Write a program to solve a Sudoku puzzle by filling the empty cells. A sudoku solution must satisfy all of the following rules: Each of the digits 1-9 阅读全文