hello
I need some help badly on this slight technicality I
am facing. I am reading every line of input into a
scalar variable, spllitting on null, to get every
character into an array, and then splicing. When I
pring the array elements of interest, a space is
appended to the input. Please help!!!
Code:
....
while(defined($line=<F>)) {
chomp($line);
....
@l = split(//, $line);
if ($l[69] eq " ") {
@right = splice(@l, 70, $#l);
@left = splice(@l, 0, 69);
print F1 "@left\n";
print F1 "+ @right\n";
}
example input: (continuuos) element 69 (at position
70)
is the space
HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH
XXXX
output:
H H H H H H H H H H H H H H H H H H H H H H H H H H H
H H H H H H H H H H H H H H H H H H H H H H H H H H H
H H H H H H H H H H H H H H H
+ X X X X
desired output would be like above output, without the
spaces!!!
so, is there a way when I splice to get rid of the
space???
thanks this is probably a lot easier than I am making
it out to be!!
__________________________________________________
Do You Yahoo!?
Yahoo! Sports - Coverage of the 2002 Olympic Games
http://sports.yahoo.com
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]