Help for this page

Select Code to Download


  1. or download this
    sub func(Int $this, Str $that) { ... }
    
    ...
    ## or with named parameters
    
    func(that => 'thing you do', this => 0xdeadbeef);
    
  2. or download this
    ($this, $that) := ( 279544, 'a string' );
    
    ## or with named parameters
    
    ($this, $that) := (that => 'thing you do', this => 0xdeadbeef);
    
  3. or download this
    sub &part(Selector $is_sheep, *@data) {
       ## body here
       return *%herd;
    }
    ($goat, $sheep) = part Animal::Cat, @animals;