Thank you very much Andy and Steve for the instructive replies.&nbsp; Have a great weekend all.<br> <br> Richard<br><br><b><i>Steven Lembark &lt;lembark@wrkhors.com&gt;</i></b> wrote:<blockquote class="replbq" style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"> <br> &gt;  I need to turn<br> &gt;<br> &gt;  $a = "now is a good time for a beer";<br> &gt;<br> &gt;  to<br> &gt;<br> &gt;  "nowisagoodtimeforabeer";<br><br>Depends on whether you want to modify the original<br>variable or not. You can remove anything with a<br>regex on the original:<br><br>     $phrase =~ s{ \s+ }{}gx;<br><br>will modify $phrase in place. You can also use a<br>regex on a copy or a join-and-split to make a new<br>copy of the variable:<br><br>     ( my $nospace = $phrase ) =~ s{ \s+ }{}gx;<br><br>or<br><br>     my $nospace = join '', split '', $phrase;<br><br>will give you a separate variable without the spaces.<br><br>-- <br>Steven Lembark                                     
    85-09 90th Street<br>Workhorse Computing                                  Woodhaven, NY 11421<br>lembark@wrkhors.com                                      +1 888 359 3508<br>_______________________________________________<br>Chicago-talk mailing list<br>Chicago-talk@pm.org<br>http://mail.pm.org/mailman/listinfo/chicago-talk<br></blockquote><br><BR><BR>A people that values its privileges above its principles soon loses both.<br> -Dwight D. Eisenhower.