Hi, This is my small portion of a bigger program. I need to concatenate 3 variables.The details are here.But output is r +esulting in 2 seperate lines rather than on a single line or in an another way I need to add \dir2 to the main directory path C: +\shyam\dir1 and final path should be "C:\shyam\dir1\dir2" when printed or accessed in program but i am get +ting as C:shyam\dir1 and \dir2 in 2 seperate lines.Because of this my + copy is failing. Please help
$\ = "\n" ; $, = "\t" ; #$|=1; use strict; use warnings; use POSIX qw[ _exit ]; use MIME::Lite; use Sort::External; use Net::Ping; use Win32::DriveInfo; $source="C:\shyam\dir1; $sym="\"; $file="dir2"; ## please note that this value is not directly assigned +but being extracted from another directory path using slicing.Ex: C:\ +sundar\dir2 $source_mod=join '',$source,$sym,$file; print "$source_mod"; Note: I have also used . opeartor but result is still the same.I am su +specting about $\="\n" in the beginning.But this is required as the o +ther part of my program needs this. Please help

In reply to concatenation of variables resulting in 2 seperate lines by rkshyam

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.