dc · online compiler

Run dc online

Run dc online — the reverse-Polish calculator, no install.

Version
Firecracker microVM live per-test verdicts multi-file compile

dc is the older, simpler, RPN-based sibling of bc — arbitrary precision, stack-based, a fun little concatenative language once you get used to postfix.

Starter code

What you get in dc

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

dc
dc 0
? 2 * p
stdin →21
expected →42
FAQ

Common questions about dc on ls-judge

GNU dc or POSIX?
GNU dc.
Is stdin supported?
Yes.
Free?
Yes.
What is the entry filename?
main.dc, piped into dc(1).
Further reading
Also try