Catalogue / calculator
calculator
MITSignedPerform mathematical calculations (add, subtract, multiply, divide). Use when you need to do any numerical calculations — never do mental math. Supports batch operations.--- name: calculator description: Perform mathematical calculations (add, subtract, multiply, divide). Use when you need to do any numerical calculations — never do mental math. Supports batch operations. ---
Calculator
Perform mathematical calculations with precision. Use this skill for ANY numerical calculations — never do mental math.
Usage
Run the bundled script with JSON operations:
bun .cursor/skills/calculator/scripts/cli.ts '<json_operations>'
Input Format
Pass a JSON array of operations, where each operation has:
operator: One ofadd,subtract,multiply,divideoperands: Array of numbers (minimum 2)
Examples
Single calculation:
bun .cursor/skills/calculator/scripts/calculator.ts '[{"operator":"add","operands":[1,2,3]}]'Multiple calculations (batched):
bun .cursor/skills/calculator/scripts/calculator.ts '[{"operator":"add","operands":[10,20]},{"operator":"multiply","operands":[5,6,2]},{"operator":"divide","operands":[100,4]}]'Output
Returns JSON with results for each operation:
{
"results": [
{ "operation": "add(10, 20)", "result": 30 },
{ "operation": "multiply(5, 6, 2)", "result": 60 },
{ "operation": "divide(100, 4)", "result": 25 }
]
}When to Use
- Always for any numerical calculation, no matter how simple
- Percentage calculations
- Unit conversions
- Aggregating numbers
- Any math where precision matters
Operation Reference
| Operator | Description | Example | |----------|-------------|---------| | add | Sum all operands | add(1,2,3) → 6 | | subtract | Subtract from first | subtract(10,3,2) → 5 | | multiply | Product of all | multiply(2,3,4) → 24 | | divide | Divide sequentially | divide(100,2,5) → 10 |
| File | Size | SHA-256 |
|---|---|---|
| SKILL.md | 1.8 kB | e617f3c89eef |
| SKILVAULT_SOURCE.json | 1.4 kB | 370a615badb8 |
| THIRD_PARTY_NOTICES.md | 1.1 kB | eacbaa9d7eac |
| scripts/cli.ts | 1.1 kB | e6084b810260 |
| src/calculator.test.ts | 4.0 kB | 71249252c878 |
| src/calculator.ts | 1.1 kB | 37e36370807e |
Published verbatim from the pinned commit. Nothing is rewritten.
| Version | Pinned commit | Signed | |
|---|---|---|---|
| 0.1.0 Current | 16db0b67ce91 | 29 Nov 2026 |
Locking a skill to one version needs Pro.