Sunday, June 21, 2026

Subline Text for Competitive Programming

Step 1: Install MinGW 

Step 2: Add to the environment variable 

Step 2: 

  • Open Sublime Text editor and then go to Tools > Build System > New Build System.
  • Paste the following code in the file and save it.
  • Name the file “CP.sublime-build“ and save it to this location- C:\Users\UserName\AppData\Roaming\Sublime Text 3\Packages\User
{
    "cmd": ["g++.exe", "-std=c++17", "${file}",
            "-o", "${file_base_name}.exe",
            "&&", "${file_base_name}.exe<inputf.in>outputf.out"],
    "shell":true,
    "working_dir":"$file_path",
    "selector":"source.cpp"
}

3. Create three new files as shown below and make sure all of them are in the same folder.

  • file.cpp: The file for writing the code.
  • inputf.in: The file where we will be giving the input.
  • outputf.out: The file where the output will be displayed.
Step - 4: 
  • Select View > Layout > Columns : 3. This will create three columns in the workspace. Move the three files into three columns.
  • Select View > Groups > Max Columns : 2.
  • Select the build system we just created from Tools > Build System > CP.
Step 5: Build using Ctr + B

You can create separate build system for any other programming language in the same way- I.E- Python 

{ "cmd": ["python", "-u", "$file", "<", "inputf.in", ">", "outputf.out"], "shell": true, "working_dir": "$file_path", "selector": "source.python" }

Save as Python.sublime-build to the same location and select build system as Python. Goto Tools-> BuildSystem->Python



Understanding AI Agents, Models, Tools, MCP, and Cost

🚀 Understanding AI Agents, Models, Tools, MCP & Cost

When I first started using Claude Code, Cursor, OpenCode, and GitHub Copilot, I had one question:

What exactly is an AI Agent?

The more I explored, the more I realized that people often mix together:

• AI Companies
• AI Assistants
• AI Models
• AI Agents
• Tools
• MCP

Here's the simplest way to think about modern AI systems:

User -> Agent -> Model -> Tools

1. User → Defines the Goal

Examples:

  • Fix the failing test
  • Create a Jira ticket
  • Deploy to Dev
  • Summarize a Slack thread

The user provides intent.


2. Model → The Brain

Examples:

  • GPT-5
  • Claude Sonnet / Opus
  • Gemini
  • DeepSeek
  • Llama

Models can:

✅ Reason
✅ Plan
✅ Explain
✅ Generate code

Models cannot:

❌ Run tests
❌ Read your files directly
❌ Create PRs
❌ Send Slack messages

A model can think.

A model cannot act.


3. Tools → The Hands

Examples:

  • Git
  • GitHub
  • Docker
  • .NET CLI
  • Jira
  • Slack

Tools execute actions.

They don't reason.


4. Agent → The Orchestrator

Examples:

  • Claude Code
  • Cursor Agent
  • OpenCode
  • GitHub Copilot Agent
  • Cline

An agent sits between the model and the tools.

Its job is to:

• Gather context
• Call the model
• Execute tools
• Verify results
• Manage workflows


The Biggest Misconception is many people think: "The model fixed my code."

What actually happened:

  1. Agent runs tests
  2. Agent sends results to the model
  3. Model analyzes the failure
  4. Agent collects more context
  5. Model proposes a fix
  6. Agent applies the change
  7. Agent reruns tests

The model decides and the agent executes.


The Real Superpower: Context Management

In a repository with:

  • 50,000 files
  • Millions of lines of code

You can't send everything to the model.

A great agent knows:

• Which files matter
• Which logs matter
• Which tests matter
• Which dependencies matter

The quality of AI output is directly tied to the quality of context.


MCP in One Sentence: MCP (Model Context Protocol) is a standard way for agents to interact with tools. Instead of building custom integrations for every service, agents can use a common interface for:

  • GitHub
  • Jira
  • Slack
  • Databases
  • Internal systems


OpenCode vs Claude Code: 

OpenCode

OpenCode -> Any Model -> Tools

Switch between Claude, GPT, Gemini, DeepSeek, OpenRouter, or local models.

Claude Code

Claude Code -> Claude Models -> Tools

A more integrated experience with less setup.


Where AI Costs Come From

The expensive part isn't dotnet test

The expensive part is:  Agent to Model communication

Every interaction consumes tokens, More context = more tokens = more cost.

A strong agent reduces cost by sending only the most relevant information instead of entire files, massive logs, and unrelated code.


In Summary

User   = Manager
Agent  = Operating System
Model  = CPU
Tools  = Peripherals

The manager defines the goal, The operating system coordinates the work, The CPU provides intelligence, The peripherals perform actions.


The future of AI isn't just smarter models.

It's:Smarter Models + Better Agents + Better Tools + Better Context Management

That's where the biggest productivity gains will come from.