3 # $Header: op.list,v 1.0 87/12/18 13:13:50 root Exp $
8 if ($foo[0] == 1 && $foo[3] == 4) {print "ok 1\n";} else {print "not ok 1\n";}
11 if ($_ eq '1:2:3:4') {print "ok 2\n";} else {print "not ok 2\n";}
13 ($a,$b,$c,$d) = (1,2,3,4);
14 if ("$a;$b;$c;$d" eq '1;2;3;4') {print "ok 3\n";} else {print "not ok 3\n";}
16 ($c,$b,$a) = split(/ /,"111 222 333");
17 if ("$a;$b;$c" eq '333;222;111') {print "ok 4\n";} else {print "not ok 4\n";}
19 ($a,$b,$c) = ($c,$b,$a);
20 if ("$a;$b;$c" eq '111;222;333') {print "ok 5\n";} else {print "not ok 5\n";}
23 if ("$a;$b;$c" eq '222;111;333') {print "ok 6\n";} else {print "not ok 6\n";}
25 ($a, $b[1], $c{2}, $d) = (1, 2, 3, 4);
26 if ($a eq 1) {print "ok 7\n";} else {print "not ok 7\n";}
27 if ($b[1] eq 2) {print "ok 8\n";} else {print "not ok 8\n";}
28 if ($c{2} eq 3) {print "ok 9\n";} else {print "not ok 9\n";}
29 if ($d eq 4) {print "ok 10\n";} else {print "not ok 10\n";}
31 @foo = (1,2,3,4,5,6,7,8);
32 ($a, $b, $c, $d) = @foo;
33 print "#11 $a;$b;$c;$d eq 1;2;3;4\n";
34 if ("$a;$b;$c;$d" eq '1;2;3;4') {print "ok 11\n";} else {print "not ok 11\n";}