Help for this page

Select Code to Download


  1. or download this
    __RESULT__
    0:10:1
    
  2. or download this
    my @a = (':','',':','');
    my $i=0;
    print join $a[$i++], 0,1,0,1; # Wrong, $i isn't incremented
    
  3. or download this
    __RESULT__
    0:1:0:1
    
  4. or download this
    print join $_ ? '' : ':', 0,1,0,1; # Wrong, $_ isn't set
    
    __RESULT__
    0:1:0:1
    
  5. or download this
    (start) 
    1. join $a[0] and $a[1]
    2. join $a[1] and $a[2]
    3. join $a[2] and $a[3] 
    (finished)
    
  6. or download this
    my $j = '';
    $j .= $_ ? length $j ? ":$_" : $_ : $_ for (0,1,0,1);
    ...
    
    __RESULT__
    0:10:1