Help for this page

Select Code to Download


  1. or download this
    $a=2;
    $a=3;
    ...
    print $a.$b   #string operator prints 2 plus the three or 23
    print $a*$b   #arithmetic operator prints 6
    print $a x $b #string operators prints $a $b times or 2 three times. i
    +e 222
    
  2. or download this
    $a=3;
    $b="x";
    ...
    $a-=2;     #$a=$a-2; $a is now equal to 3;
    $b x=3;    #$b=$b x $3 $b is now equal to "xxx";
    $b .="33"; #b=$b."33"  $b is now equal to "xxx33";
    
  3. or download this
    $a=1;
    print $a++; #prints a as one then adds 1 to it
    print $a;   #now $a is 2
    print ++$a; #adds one to $a and then prints its value which is now 3;
    print $a--; #prints 3 then subtracts one from $a;