Alt Factorial
alt_factorialThe alternating factorial af(n) = n! - (n-1)! + (n-2)! - ... ending at 1. af(1) is 1, af(3) is 5, and af(4) is 19. n runs from 1 to 200. Past 15 digits the value is a decimal string. Price: $0.001 USDC per successful call (x402, Solana). Same tool over HTTPS: POST https://scorptech.it.com/api/x402/v1/alt-factorial
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": {
"n": "<n>"
},
"name": "alt_factorial"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| n | Yes |