yeah, so can i do that?
i have a program already written that has two functions.. and one is recursive.. so i want to know how can i execute just one line of code at a time by pressing a button.. i hope it's possible
and also i'm doing this in a web page
this is my script.. it has no importance but just for you to make an idea..
READ THIS... i don't want to debug it with firebug or whatever... i want to make this myself inside my program... i want to make the code execute 1 line at a time when i press a button..so basically im building my own debugger.. the graphical part is already done.. i only need to know how to do this..
function nod(){
var info;
var st;
var dr;
}
function help(){
var rad;
}
var h = new help();
h.rad = new nod();
h.rad = null;
function create(h,x)
{
if(h.rad==null)
{
h.rad = new nod();
h.rad.info = x ;
h.rad.st = h.rad.dr = null;
}
else{
if(x < h.rad.info){
var h1;
h1 = new help();
h1.rad = h.rad.st;
create(h1,x);
h.rad.st = h1.rad;
}
else{
var h2;
h2 = new help();
h2.rad = h.rad.dr;
create(h2,x);
h.rad.dr = h2.rad;
}
}
}
function read(h)
{
var input = [0,10,2,1,8,9,4,5,3,6,20,11,30,21,31,22,23,
];
var i;
for(i=1;i<=16;i++)
{
create(h,input[i]);
}
}
read(h);