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

Re: Determine if array value in string results

by james28909 (Deacon)
on Nov 21, 2018 at 17:48 UTC ( #1226137=note: print w/replies, xml ) Need Help??


in reply to Determine if array value in string results

Can you show us the code that you have tried? The code thats not working?

What it sounds like to me is that you are trying to loop through an array with 900+ elements and find the ones that match "valuen".

use strict; use warnings; my @array = qw(valuen valued valuec valueq values); for (@array) { if (/valuen/) { print; } else { print ";"; } }

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (3)
As of 2020-04-05 23:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    The most amusing oxymoron is:
















    Results (36 votes). Check out past polls.

    Notices?