Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: extracting data from a file

by frozenwithjoy (Curate)
on Dec 14, 2012 at 07:17 UTC ( #1008786=note: print w/ replies, xml ) Need Help??


in reply to extracting data from a file

You could just capture stretches of non-quote characters that are between quotes:

#!/usr/bin/env perl use strict; use warnings; use feature 'say'; my $string = q("qazwsx" "edcrfv" "tgbyhn"); my @array = $string =~ /"([^"]*)"/g; say $_ for @array; __END__ qazwsx edcrfv tgbyhn


Comment on Re: extracting data from a file
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1008786]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2014-09-02 00:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (18 votes), past polls