data-structure-selection
Choosing optimal data structures based on access patterns and performance requirements.
от sethdford★ 51 звезда на GitHub
Установить data-structure-selection в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Data Structure Selection
Matching data structures to your performance requirements.
Context
You are selecting data structures. Understand tradeoffs: access time, insertion, deletion, memory.
Domain Context
- Array: O(1) random access; O(n) insertion
- Linked List: O(n) random access; O(1) insertion (if you have pointer)
- Hash Table: O(1) average access; O(n) worst case
- Tree: O(log n) balanced access; O(n) unbalanced
- Heap: O(1) min/max; O(log n) insertion
Instructions
- Analyze Access Patterns: Read-heavy? Write-heavy? Random access? Ordered?
- Identify Bottleneck: Insertion? Lookup? Iteration?
- Compare Options: List pros/cons of 2-3 structures
- Benchmark: If unclear, measure with realistic data
- Choose: Select structure with best worst-case for bottleneck
- Monitor: Track performance; be ready to change if patterns shift
Anti-Patterns
- Choosing structure based on familiarity not performance
- Not considering space overhead; 10x lookup speedup doesn't matter if memory explodes
- Using unbalanced trees; always use balanced (AVL, Red-Black, B-Tree)
- Ignoring cache locality; array beats linked list even with worse complexity
- Micro-optimizing data structures while algorithmic cost dominates
Further Reading
- Donald Knuth, The Art of Computer Programming
- MIT OpenCourseWare, Introduction to Algorithms
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл data-structure-selection?
Choosing optimal data structures based on access patterns and performance requirements.
Как установить скилл data-structure-selection?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл data-structure-selection запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
AnthropicCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
discernment-nudge
AnthropicAfter you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
data-consolidate
AnthropicJoins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
inspection-to-capa
AnthropicRuns the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…