perl中的"标量的实验值现在被禁止"问题

and*_*ier 0 perl

在Perl 5.26.1中,我得到:

Experimental each on scalar is now forbidden at a.plx line 67.
Type of arg 1 to each must be hash or array (not private variable) at a.plx   
line 67, near "$val)"
Execution of a.plx aborted due to compilation errors.
Run Code Online (Sandbox Code Playgroud)

第67行是其中的

 67         while (my ($ip, $val2) = each($val))
 68         {
                   ......
            }
Run Code Online (Sandbox Code Playgroud)

Sou*_*dar 6

检查here......

脚本:

var ul = document.createElement("ul");
document.body.appendChild(ul);

for (var i = 1; i <= 10; i++)
{
    var li = document.createElement("li");  
    li.className = "file";

    var a = document.createElement("a");
    a.innerHTML = "Subfile " + i;

    li.appendChild(a);
    ul.appendChild(li);
}
Run Code Online (Sandbox Code Playgroud)

像这样你可以创建你想要的订单..