編輯

共用方式為


WorksheetFunction.Combin(Double, Double) Method

Definition

Returns the number of combinations for a given number of items. Use Combin to determine the total possible number of groups for a given number of items.

public:
 double Combin(double Arg1, double Arg2);
public double Combin (double Arg1, double Arg2);
Public Function Combin (Arg1 As Double, Arg2 As Double) As Double

Parameters

Arg1
Double

The number of items.

Arg2
Double

The number of items in each combination.

Returns

Remarks

Numeric arguments are truncated to integers.

If either argument is nonnumeric, Combin generates an error.

If number < 0, number_chosen < 0, or number < number_chosen, Combin generates an error.

A combination is any set or subset of items, regardless of their internal order. Combinations are distinct from permutations, for which the internal order is significant.

The number of combinations is as follows, where number = n and number_chosen = k:

Figure 1: Number of combinations

Where:

Figure 2: Equation

Applies to