Location:
Search - wodechengx
Search list
Description: 本程序实现的是一个对于一个给定的数字集合,再给一个数字限制,求得这个集合的所有子集合,使子集合的各个元素之和为给定的数字限制,如果没有这样的子集合,则输入为空!
程序本身运用的是回朔算法,但是值得注意的是,我用的是非递归的形式实现的,所以就显现出了一定的难度.
-this program is one for a given set of figures, to give a figure restrictions this assembly obtained all the subset, so subset of the various elements and as to the number of restrictions, if there is no such subset, the importation of empty! the process itself is the use of algorithms to Schomburg, but noteworthy, I use a non- recursive achieved in the form of, and so they showed a certain degree of difficulty.
Platform: |
Size: 33792 |
Author: 支新辉 |
Hits: