A local DSA practice tool

Practice, without the noise.

Carrel opens in your browser, runs your Java or C++ with the compilers already on your computer, and saves your code as plain files. No account. No subscription. Works offline.

curl -fsSL https://saurabhraghuvanshii.github.io/carrel/install.sh | sh
See how it works

Windows: irm https://saurabhraghuvanshii.github.io/carrel/install.ps1 | iex

Mac, Linux and Windows. Needs Java or C++ installed. Run carrel doctor to check.

Each square is one test case. A submit runs 5 fixed cases and 50 random ones.

From the maker

Why I made this

I kept my practice in a folder of Java files. It worked for my code, and for nothing else. No problem text, no tests, no order to follow.

The places that had those wanted an account, then a subscription, then a good connection. I wanted something smaller. Open it, pick a problem, write code, see if it passes. On a train, on a weak connection, on a laptop that has nothing but a compiler.

So I built Carrel. It is one small program. It uses the compilers already on your computer, so there is nothing to sign in to and no sandbox to download. Your code is plain files in a folder you can open, copy, or put in git.

I made it calm on purpose. A warm page, one accent colour, and a tag on every problem so you know what you are walking into. Nothing flashes while you think.

Saurabh

The problem

What usually gets in the way of practice

An account before the first problem

Sign up, verify, pick a plan. Then you get to practise.

With Carrel

One command. No account, no plan.

Nothing works offline

A flight, a power cut or a weak connection ends the session.

With Carrel

Everything runs on your computer. Only the optional AI hints need a network.

Tests you can learn by heart

A fixed list gets memorised. A wrong answer can pass by luck.

With Carrel

Fifty new random cases on every submit, plus the fixed ones.

A heavy editor for a short answer

Most problems are twenty lines. Waiting for a big app to load is not practice.

With Carrel

One small program. The server is ready in about 30 ms on our test machine.

How it works

Three steps, nothing to set up

  1. 1

    Install

    curl -fsSL https://saurabhraghuvanshii.github.io/carrel/install.sh | sh

    One file, no dependencies. It goes in your home folder and needs no admin rights.

  2. 2

    Run

    $ carrel doctor
    java   found
    g++    found
    
    $ carrel
    ready on http://127.0.0.1:7777

    Your browser opens. The server only listens on your own computer.

  3. 3

    Practise

    pick a problem
    write Java or C++
    press Submit

    Your code saves as you type. Close the tab and pick up where you left off.

What a submit does

Every submit is a fresh test

Random cases come from a seeded generator that already knows the answer, so Carrel can check yours without any AI. If a case fails, the seed lets you run it again.

  1. 1

    Compile once

    Your code is built one time. Every case then runs in the same process.

  2. 2

    5 fixed cases

    The examples and the edge cases the problem author picked.

  3. 3

    50 random cases

    New inputs from a seeded generator that knows the right answer.

  4. 4

    One clear result

    Pass or fail, the failing case, and the seed to repeat it.

When a case fails

Failed on random case 31 of 50      seed 48213
input     nums = [7, 2, 11, 5, 10, 4], target = 13
expected  [1, 2]
got       [0, 5]

Sheets

Two sheets, one calm list

Patterns teaches one idea at a time, in learning order, about a hundred problems.

Real interviews are longer, story-style problems like dispatching a driver or limiting requests, each with a follow-up question.

Every problem carries a tag: Easy, Medium or Hard.

Yours to keep

Your code stays on your computer

Plain files

Every solution is a normal file. Open it in any editor, put the folder in git, or export it all as one zip.

~/.carrel/
  solutions/
    pair-with-target-sum.java
    nearest-available-driver.cpp
  progress.json

Hints, only if you want them

Paste your own API key in settings and Carrel can explain a problem or nudge you. It is told to explain and hint, never to hand over the full answer. Off until you turn it on.

  • Anthropic
  • OpenAI
  • Ollama, on your machine

Your key is kept in a file only you can read. It is never sent to the page.

Looks

Calm by default. Yours if you like.

Two themes and five accent colours. Easy, Medium and Hard keep the same colours everywhere, so a tag always reads the same. Try it. This page changes too.

Theme
Accent
Difficulty
EasyMediumHard

Questions

Short answers

Is it free?

Yes. Carrel is free and runs on your computer. There is no account to make.

Does it work offline?

Yes. Problems, tests and your code all stay on your computer. Only the optional AI hints need a network.

Which languages?

Java and C++ to start. Carrel uses the javac and g++ already installed on your computer. More languages are planned.

Where is my code?

In plain files in ~/.carrel/solutions. Open them anywhere, or put the folder in git.

Does it send my code anywhere?

No. If you turn on AI hints and press Ask, that one question goes to the provider you chose, using your own key.

Are these real company questions?

No. Every problem is written from scratch. Some follow patterns commonly seen in online assessments, but none are copied from any site or company.

Open it and start.

One command, then your first problem.

curl -fsSL https://saurabhraghuvanshii.github.io/carrel/install.sh | sh
View on GitHub