首页 > ACM题库 > HDU-杭电 > hdu 4477 Cut the rope II待解决[解题报告]C++
2015
07-16

hdu 4477 Cut the rope II待解决[解题报告]C++

Cut the rope II

问题描述 :

  We have a rope whose length is L. We will cut the rope into two or more parts, the length of each part must be an integer, and no two parts have the same length.
  Your task is to calculate there exists how many results after the cutting. We say two results are different if and only if there is at least one part, which we can find in one result but can not find in the other result.

输入:

  There is an integer T (1 <= T <= 50000) in the first line, which indicates there are T test cases in total.
  For each test case, there is only one integer L (1 <= L <= 50000) which has the same meaning as above.

输出:

  There is an integer T (1 <= T <= 50000) in the first line, which indicates there are T test cases in total.
  For each test case, there is only one integer L (1 <= L <= 50000) which has the same meaning as above.

样例输入:

3
2
3
6

样例输出:

0
1
3