--- Jennifer Pan <[EMAIL PROTECTED]> wrote:
> Hello all, 
> 
> I stdin a file name: xxx.txt
> and I would like to have a output file name called x.txt.yyy
> 
> This is how I do it 
> 
> $FILENAME = <STDIN>;
> $output = "$FILENAME.y";
> print "$output";

I suspect the problem in the newline you get from STDIN....

> And the result is only
> .yyy

Isn't it the value of $FILENAME on one line, and .yyy on the next?
 
> How do I concatenate $FILENAME and .yyy? 

Exactly as suggested by others here on the list.
chomp $FILENAME after you read it from STDIN to remove the trailing
newline, and then do what you're already doing. =o)

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

Reply via email to