我正在接收某个进程的输出(如下@result_listosp
所示)。当我尝试 chomp 输出时很奇怪。我想要以下输出:
origin-server-pool-1 http_TestABC https_TestABC
代码:
use strict;
use warnings;
my @result_listosp = ( # From backticks
"origin-server-pool-1\n",
"http_TestABC \n",
"https_TestABC\n",
);
chomp @result_listosp;
输出:
origin-server-pool-1http_TestABC https_TestABC