infix (+), infix ⊎
Documentation for infix
(+), infix ⊎ assembled from the following types:
Returns the Baggy addition of its arguments. More information.
multi sub infix:<(+)>(**)
Returns the Baggy addition of its arguments. This creates a new Bag from each element of the arguments with the weights of the element added together to get the new weight, if none of the arguments are a Mix or MixHash.
say <a a b c a d> (+) <a a b c c>; # OUTPUT: «Bag(a(5) b(2) c(3) d)␤»
If any of the arguments is a Mixy, the result is a new
say <a b c> (+) (a => 2.5, b => 3.14).Mix; # OUTPUT: «Mix(a(3.5) b(4.14) c)␤»