Advertisement
Guest User

Untitled

a guest
Dec 9th, 2016
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. my Str $test = q{ULL
  2. RRDDD
  3. LURDL
  4. UUUUD
  5. };
  6. subset DirectionList of List where { .map({$_ ~~ Str and $_ ~~ 'U'|'D'|'L'|'R'|"\n"}) ==> reduce { $^a and $^b} }
  7. say $test.comb ~~ DirectionList;
  8. sub dl(DirectionList $d) is export {
  9. for $d {
  10. say $_;
  11. }
  12. }
  13. dl($test.comb);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement