in reply to IN-style operator for set of possible values

... typically [hashes] are used..., but it's less elegant because I'd have to create the hash just for the comparison.

In all the pseudo or real solutions
    if ($myfruit in ("bananas","apples","oranges")){ ... }
    if ("bananas" ~~ ["bananas","apples","oranges"]) { ... }
    if (grep { $myfruit eq $_ } qw(bananas apples oranges)){ ... }
a set must be created just for the comparison. (However, the match, smart-match and grep solutions allow matching for something other than equality.)