combinations
Calculate the number of ways to choose r items from n items without regard to order, returning exact result as a decimal string.
Instructions
Calculates n choose r exactly when order does not matter; returns a decimal string
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"total": "<total>",
"selected": "<selected>"
},
"name": "combinations"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| total | Yes | Total number of items, n | |
| selected | Yes | Number of selected items, r |