摘要: Problem DescriptionHassan is in trouble. His mathematics teacher has given him a very difficult problem called 5-sum. Please help him. The 5-sum problem is defined as follows: Given 5 sets S_1,...,S_5 of n integer numbers each, is there a_1 in S_1,...,a_5 in S_5 such that a_1+...+a_5=0?InputFirst li 阅读全文
posted @ 2013-05-19 11:14 forevermemory 阅读(218) 评论(0) 推荐(0) 编辑
摘要: Problem Description Haoren is very good at solving mathematic problems. Today he is working a problem like this: Find three positive integers X, Y and Z (X < Y, Z > 1) that holds X^Z + Y^Z + XYZ = K where K is another given integer. Here the operator “^” means power, e.g., 2^3 = 2 * 2 * 2.... 阅读全文
posted @ 2013-05-19 01:41 forevermemory 阅读(209) 评论(0) 推荐(0) 编辑