On 10/7/18 5:47 PM, Brad Gilbert wrote:
I think the easiest way to get a 400 characters from a file is with
.comb() on the file.
'example.txt'.IO.comb(400).head()
On Sun, Oct 7, 2018 at 6:42 PM ToddAndMargo via perl6-users
<perl6-us...@perl.org> wrote:
Hi All,
I use `slurp` all the time, so of course, I can't
make heads or tails out of
https://docs.perl6.org/routine/slurp
I want to slurp the first 400 characters of
a file and close the handle. Am I missing a
`so many` parameter somewhere?
Many thanks,
-T
Hi Brad,
The files I will be examining are upwards to 250 MB.
So I really only want the first 400 bytes.
I read
https://docs.perl6.org/routine/comb
and could ot make heads or tails out of it. But
don't try to explain it to me -- that is a job for
another day.
Thank you!
-T