Competitive Programming Templates
A powerful VS Code extension that helps competitive programmers manage and use code templates efficiently through snippets and commands.
🚀 Features
1. Snippet-based Template Usage
- Start typing template names to get suggestions
- Available snippets:
uf - UnionFind data structure
bs - Binary Search implementation
bm - Bitmasking template
- And more!
2. Right-Click Template Creation
- Select any code in your editor
- Right-click and choose "Create CP Template from Selection"
- Name your template
- Instantly available as a snippet!
3. File-based Template Import
- Import existing template files
- Supports multiple languages (C++, Python, Java)
- Templates are stored globally
📥 Installation
- Open VS Code
- Go to Extensions (Ctrl+Shift+X)
- Search for "Competitive Programming Templates"
- Click Install
🎯 Quick Start
Using Snippets
- Open a .cpp or .py file
- Type one of these triggers:
uf for UnionFind
bs for Binary Search
bm for Bitmasking
- Press Tab to insert the template
Creating New Templates
Method 1: From Selection
- Select code in editor
- Right-click
- Choose "Create CP Template from Selection"
- Enter template name
Method 2: From File
- Press Ctrl+Shift+P
- Type "CP: Create New Template"
- Select your template file
- Enter template name
🔧 Requirements
- Visual Studio Code ^1.96.0
🤝 Contributing
See our Contributing Guide for details.
📝 License
MIT License - see LICENSE
🆘 Support
Found a bug? Have a feature request? Open an issue
| |