online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
from decimal import Decimal class Money: def __init__(self, amount: Decimal, currency: str, precision: int = 2): self.amount = amount self.currency = currency self.precision = precision def __str__(self): return f"{self.amount:.{self.precision}f} {self.currency}" def __repr__(self): return f"Money({self.amount!r}, {self.currency!r}, {self.precision!r})" money = Money(1234.123, "Pln", 3) print(money) money = Money(123.123, "Pln") print(money) money = Money(1234.123, "Pln", 4) print(money)

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text
×

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue