combinations
How to determine best combinations from 2 lists
I\'m looking for a way to make the best possible combination of people in groups. Let me sketch the situation.[详细]
2023-03-28 05:26 分类:问答Algorithm for: All possible ways of splitting a set of elements into two sets?
I have n elements in a set U (lets assume represented by an array of size n). I want to find all possible ways of dividing the set U into two sets A and B, where |A| + |B| = n.[详细]
2023-03-26 20:13 分类:问答Recursive Algorithm to find Combinations of a set in Java
I was trying to find some examples on how to find a given set\'s (may be string or array of integers) all com开发者_如何转开发binations in Java. And I have came across this code piece (found in http:/[详细]
2023-03-26 13:26 分类:问答Algorithm for puzzle game
I\'m working on a game and I\'m struggling to get some generic functionality. Suppose we have a phrase like \"puzzle game using group of words\" so I generate possible subsets from this:[详细]
2023-03-26 11:33 分类:问答LINQ implementation of Cartesian Product with pruning
I hope someone is able to help me with what is, at least to me, quite a tricky algorithm. The Problem I have a List (1 <= size <= 5, but size unknown until run-time) of Lists (1 <= size <[详细]
2023-03-26 04:18 分类:问答List all combinations of 4 operators and 4 numbers then test their final value C#
I\'m trying to make a 24 solver (the game 24\'s objective is to use +,-,*,/ to get to the number 24) I\'m reasonably confident that the only way to do this is using a brute force method (try each com[详细]
2023-03-25 14:29 分类:问答Best way to generate pascal's triangle (of two mentioned ways)
I have an programming assignment in Java. I have implemented it by making an nCr ( http://en.wikipedia.org/wiki/Combination ) function then using a double for loop to make the triangle by printing it[详细]
2023-03-25 02:48 分类:问答R: Generating all permutations of N weights in multiples of P
I need to create a function (in R) which: - given N possible variables to attribute weights to; - creates all possible permuati开发者_Python百科ons of weights (summing to 100%);[详细]
2023-03-24 07:41 分类:问答Find highest total price by selling items to multiple buyers, limited by user input to how many separate sales can be made
EDIT: Im sorry guys my explantion of the problem wasn\'t clear! This should be better: User sends ID numbers of articles and the max. number of bundles(packages)[详细]
2023-03-23 16:01 分类:问答Given a list of elements in lexicographical order (i.e. ['a', 'b', 'c', 'd']), find the nth permutation - Average time to solve?
I stumbled across this interview question: Given a list of elements in lexicographical order (i.e. [\'a\', \'b\', \'c\', \'d\']), find the nth permutation[详细]
2023-03-22 06:54 分类:问答