in this program we have to make a kill function that kill to the right using a link list and a skip number. so if i have a b c d and skip one.
a kills c
d kills b
a kills a
d wins
i using this loop
while(size!=1)
{
pos=0;
kill (head,pos,skipNum,success,size--,killvic); killvic.killer=retrieve(head,1+findNodeKiller(head,pos,killvic)),success);
}
if you could add some comments explaining what each function does, because folowing 3 functions one inside another and on top of that there are missing variables and functions it's kind of a pain trying to understand it.
and when inserting code please use [ code] [ /code] to separate it from the rest of the text, plus it highlights the c++ sintax.