online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
''' Welcome to GDB Online. GDB online is an online compiler and debugger tool for C, C++, Python, Java, PHP, Ruby, Perl, C#, OCaml, VB, Swift, Pascal, Fortran, Haskell, Objective-C, Assembly, HTML, CSS, JS, SQLite, Prolog. Code, Compile, Run and Debug online from anywhere in world. ''' def solve(arr): if not arr: return [] tmp = [] ret = [] for x in arr: if not ret or ret[-1] < x: ret.append(x) else: tmp.append(x) return ret + solve(tmp) print(solve([0,0,1,1,1,2,2,3,3,4])) print(solve([2,2,3,4,4]))

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