online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
{ Online Pascal Compiler. Code, Compile, Run and Debug Pascal program online. Write your code in this editor and press "Run" button to execute it. } program Hello; type tRefKante = ^tKante; tKante = record von: integer; zu: integer; x:boolean; next: tRefKante end; procedure push(inVon:integer; inZu:integer; var ioG:tRefKante); var n:tRefKante; begin new(n); n^.von := inVon; n^.zu := inZu; n^.x := false; n^.next := ioG; ioG := n end; function get(inG:tRefKante; inVon:integer):tRefKante; var n:tRefKante; begin get := nil; n := inG; while (n <> nil) do begin if ((n^.von = inVon) and (not n^.x)) then get := n; n := n^.next; end; end; function wasPassiert(inG:tRefKante; inVon:integer; inZu:integer):tRefKante; var akt:integer; kante:tRefKante; B:tRefKante; begin akt := inVon; B := nil; while ((akt <> inZu) and (akt <> 0)) do begin kante := get(inG,akt); if (kante <> nil) then begin push(kante^.von,kante^.zu,B); akt := kante^.zu; kante^.x := true end else begin if (B <> nil) then B := B^.next; if (B = nil) then akt := 0 else akt := B^.zu end; end; wasPassiert := B end; procedure print(inGraph:tRefKante); var e,f : tRefKante; begin e := inGraph; while (e^.next <> nil) do begin e := e^.next; end; write('[',e^.von, ',', e^.zu,']'); while (e <> inGraph) do begin f := inGraph; while (f^.next <> e) do begin f := f^.next end; write('[',f^.von, ',', f^.zu,']'); e := f end; end; var A: tRefKante; begin push(8,9,A); push(4,99,A); push(8,10,A); push(10,8,A); push(4,10,A); push(4,3,A); push(3,4,A); print(wasPassiert(A,3,99)); end.

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