-
-
Save Timbus/415d0d358e676afae647 to your computer and use it in GitHub Desktop.
I.. uh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
my $test-str = "asdf\nfdsa\nqwer\nrewq\n\nffff\ndddd"; | |
> my ($map, $words) = $test-str.split("\n\n"); $map .= split("\n"); $map.perl | |
().list.item | |
> my ($map, $words) = $test-str.split("\n\n"); $map .= split("\n"); | |
asdf fdsa qwer rewq | |
> $map.perl | |
("asdf", "fdsa", "qwer", "rewq").list.item | |
#Also this: | |
> my ($map, $words) = $test-str.split("\n\n")>>.split("\n").tree | |
#Empty | |
> my ($map, $words) = $test-str.split("\n\n")>>.split("\n").lol | |
#Empty again | |
#Works without assignment. | |
> $test-str.split("\n\n")>>.split("\n").lol.perl | |
LoL.new(("asdf", "fdsa", "qwer", "rewq").list.item, ("ffff", "dddd").list.item) | |
#Works if I don't actually perform the splitting.. | |
> my ($map, $words) = LoL.new(("asdf", "fdsa", "qwer", "rewq").list.item, ("ffff", "dddd").list.item) | |
asdf fdsa qwer rewq ffff dddd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment