Are you sure the values in your for loop in the sub are what you expect?
... for($i=1;$i<=$k;$i++){ print "i = $i, j= $j\n"; # Added to debug ...
I think you'll find the following does the trick:
for($i=1;$i<$k;$i++){
(Less than versus less than/equal to)
In reply to Re: problem in my sub partition
by VinsWorldcom
in thread problem in my sub partition
by PhillipHuang
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |