Skip to content
Back to skills

Combinatorics Calculator

ASecurity

Calculate combinatorial values with modular arithmetic

  • 1,760 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 2, 2026
ai-agentsgobackend

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned September 2, 2026

npx -y skills add a5c-ai/babysitter --skill combinatorics-calculator --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Combinatorics Calculator?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Combinatorics Calculator
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/a5c-ai-combinatorics-calculator-babysitter/badge)](https://www.skillsdirectory.com/skills/a5c-ai-combinatorics-calculator-babysitter)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: combinatorics-calculator
description: Calculate combinatorial values with modular arithmetic
allowed-tools:
  - Read
  - Write
  - Grep
  - Glob
  - Edit
graph:
  domains: [domain:computer-science]
  specializations: [specialization:algorithms-optimization]
  skillAreas: [skill-area:dynamic-programming, skill-area:mathematical-reasoning]
  roles: [role:backend-engineer, role:computational-scientist]
---

# Combinatorics Calculator Skill

## Purpose

Calculate combinatorial values with modular arithmetic support for competitive programming applications.

## Capabilities

- Factorial and inverse factorial precomputation
- nCr, nPr with modular arithmetic
- Catalan, Stirling, Bell numbers
- Lucas theorem implementation
- Inclusion-exclusion principle application
- Generating functions

## Target Processes

- combinatorics-counting
- number-theory-algorithms
- dp-pattern-matching

## Combinatorial Functions

### Basic Counting
- Factorial: n!
- Permutations: P(n,r) = n!/(n-r)!
- Combinations: C(n,r) = n!/(r!(n-r)!)

### Special Numbers
- Catalan numbers
- Stirling numbers (first and second kind)
- Bell numbers
- Derangements

### Advanced Techniques
- Lucas theorem (for large n, small p)
- Inclusion-exclusion
- Burnside's lemma
- Generating functions

## Input Schema

```json
{
  "type": "object",
  "properties": {
    "operation": {
      "type": "string",
      "enum": ["nCr", "nPr", "factorial", "catalan", "stirling", "lucas", "precompute"]
    },
    "n": { "type": "integer" },
    "r": { "type": "integer" },
    "mod": { "type": "integer" },
    "precomputeLimit": { "type": "integer" }
  },
  "required": ["operation"]
}
```

## Output Schema

```json
{
  "type": "object",
  "properties": {
    "success": { "type": "boolean" },
    "result": { "type": "integer" },
    "code": { "type": "string" },
    "formula": { "type": "string" }
  },
  "required": ["success"]
}
```

Files in this skill

  • README.md690 B
  • SKILL.md1.9 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.