Help for this page

Select Code to Download


  1. or download this
    foreach(@stack1){
        my $qq = pop(@stack1);
        print "$qq popped from end of queue\n";
        print "left on stack : @stack1 \n";
        print "stack size is $#stack1 \n";
    }
    
  2. or download this
    while(@stack1){
        my $qq = pop(@stack1);
        print "$qq popped from end of queue\n";
        print "left on stack : @stack1 \n";
        print "stack size is $#stack1 \n";
    }