摘要:
British astronomer Eddington liked to ride a bike. It is said that in order to show off his skill, he has even defined an "Eddington number", E -- tha 阅读全文
摘要:
The K−P factorization of a positive integer N is to write N as the sum of the P-th power of K positive integers. You are supposed to write a program t 阅读全文
摘要:
It is said that in 2011, there are about 100 graduate schools ready to proceed over 40,000 applications in Zhejiang Province. It would help a lot if y 阅读全文
摘要:
wpl指的是树的带权路径长度,是所有叶节点的权值乘以叶节点的深度之和,WPL=∑(叶节点的权值)*(叶节点的深度) #include<iostream> using namespace std; const int MAXSIZE=0x0000ffff; struct BiTree{ int wei 阅读全文
摘要:
首先明确线索二叉树的概念,线索二叉树是原本二叉树n个节点中未分配的n-1个孩子指针改为线索指针,左孩子指向前驱结点,右孩子指向后继节点。 中序线索二叉树的构造就要明确中序遍历: #include<iostream> using namespace std; struct BiTree{ int da 阅读全文
摘要:
This time, you are supposed to find A+B where A and B are two polynomials. Input Specification: Each input file contains one test case. Each case occu 阅读全文