To define a variable in Perl is pretty simple. A variable preceded with $ can present number, string, etc. When we want to present a long string, in order to avoid being misinterpreted we need put '\' to skip some charactor such as '%','%' ect.
One simple way is using a subroutine like below,
but it cannot handle '@'.
sub GetLongString {
return << "LONG";
WHATEVER $%!~(*&^)(
LONG
}
No comments:
Post a Comment