Help for this page

Select Code to Download


  1. or download this
    >perl -E"say 'ok' if 'a' ~~ ('a', 'b');"
    
    >perl -E"say 'ok' if 'b' ~~ ('a', 'b');"
    ok
    
  2. or download this
    say "ok" if "a" ~~ X;
    
  3. or download this
    say "ok" if "a" ~~ scalar(X);
    
  4. or download this
    >perl -E"use constant X => qw(a b c); say 'ok' if 'a' ~~ @{[ X ]}"
    ok