online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
def addData(data): try: if isinstance(data, str): with open("data.txt", "a") as file: file.write(data + "\n") return "Done" else: raise TypeError("Type error") except FileNotFoundError: return "Error: File not found." except PermissionError: return "Error: Writing to file" except Exception as e: return str(e) returnValue = addData("The larch") print(returnValue) returnValue = addData(123) print(returnValue)
Monty Python

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