test for remaining tasks

while(!empty(&s))