Run Nim 2 online — Python-clean syntax, C-fast binaries.
Nim reads like Python and compiles to C (also C++, JS, ObjC). Statically typed, garbage collected (with options), templates and macros for metaprogramming.
ls-judge compiles Nim 2.x with the standard compiler inside a Firecracker microVM.
Clicking "Run now" opens the playground with this exact code and a matching test case pre-loaded — passes on first Run.
import strutils
let n = parseInt(readLine(stdin))
echo n * 2
21
42