P is for Practical | |
PerlMonks |
Re: outputs followed by each otherby 1nickt (Canon) |
on Feb 16, 2018 at 00:26 UTC ( [id://1209262]=note: print w/replies, xml ) | Need Help?? |
Hi, the value of your variables includes the new line character that was added when the user hit 'Enter'. It's a good idea to examine variable values enclosed in delimiters so you can spot any invisible characters, like this: print ">$var<"; You can remove the newline character with chomp. Hope this helps!
The way forward always starts with a minimal test.
In Section
Seekers of Perl Wisdom
|
|