online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
def myFunction(base, plus): result = [] for bas in base: lastElem = bas[-1:][0] for x in plus: result.append(bas + ( (lastElem+x),) ) return result first_elem = [(18,)] add = [6,0,-6] print(myFunction(first_elem, [6,0,-6])) #[(18, 24), (18, 18), (18, 12)] print(myFunction([(18, 24), (18, 18), (18, 12)], [6,0,-6])) #[(18, 24, 30), (18, 24, 24), (18, 24, 18), (18, 18, 24), (18, 18, 18), (18, 18, 12), (18, 12, 18), (18, 12, 12), (18, 12, 6)]

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