Python · online compiler

Run Python online

Run Python online — real CPython 3.11 → 3.15 (RC), no install, sandboxed per submission.

Firecracker microVM live per-test verdicts multi-file compile

Python is the most-taught programming language in the world, the default for data science and AI, and the fastest way to sketch an idea into working code. If you are learning to code, this is where you start.

ls-judge runs real CPython — not a stripped-down browser Python — inside a Firecracker microVM (the same primitive AWS Lambda uses). You get the full stdlib, real file I/O, real subprocess, real everything. Pick your version: 3.11 for the LTS mainstream, 3.13 for improved error messages, 3.14 for the very latest.

Bring a single file, or use the multi-file panel to include your helper modules — they will be picked up on the same PYTHONPATH as the entry file.

Stdin from the Tests panel maps to sys.stdin. Verdicts (AC/WA/TLE/RE) stream back per test case over WebSocket, so watching a solution against 100 cases is immediate rather than "run and wait".

If your program is doing tight numerical loops and you want more speed, see /lang/pypy for the JIT-compiled sibling.

Starter code

What you get in Python

Clicking "Run now" opens the playground with this exact code and a matching test case pre-loaded — passes on first Run.

python
Python 3.15
n = int(input())
print(n * 2)
stdin →21
expected →42
FAQ

Common questions about Python on ls-judge

Which Python versions do you support?
CPython 3.11, 3.12, 3.13, and 3.14 — the picker on the playground lets you switch between them per submission.
Are numpy / pandas / scikit-learn installed?
Not on the free tier — the sandbox has no network to pip install and no pre-baked scientific stack. Use standard library only, or write pure-Python code.
How is it sandboxed?
Every submission runs in its own Firecracker microVM with a fresh kernel, jailer chroot, and hermetic network namespace — the same isolation model AWS Lambda uses.
Is there a REPL?
The playground is file-based (edit, Run, see results per test) rather than a REPL. Interactive input is via the Tests panel's stdin field.
Further reading
Also try