You are right about warnings and strict I'm just frustrated trying to get this to work and I sort of developed a code writer's block from this. I'm not a 100% sure on what your saying? Are you suggesting this as I showed.
$1 = "Cell ID for First Cell: MCC: 310 MNC: 64 LAC: x'44D CI: x'MAD +023"; #This is what I want to print. %Firstcell = ( "Cell ID for First Cell: MCC: 310 MNC: 64 LAC: x'44D CI: x'4F07", " +Cell ID for First Cell: MCC: 310 MNC: 64 LAC: x'44D CI: x'MAD023", Cell ID for First Cell: MCC: 310 MNC: 64 LAC: x'44D CI: x'270B", "C +ell ID for First Cell: MCC: 310 MNC: 64 LAC: x'44D CI: x'APPL2B");
Now you say I don't need to grab the line with a regex match and you then say I need one to capture it? I'm kinda unclear there. See I don't know what the numbers on the end will be so I can't use grep to capture it.

So you're saying like this -
if ($lastheading = "MSTerminating") { if (grep "$1", @lines) { print "$_"; } }
I only have one problem. For some damn reason "$_" won't print anything. I have:
while ($para = <>) {
but that should still print "$_"

Anyway is what you were talking about something like the above cuz I don't get what you're saying.

The Brassmon_k

In reply to Re: Re: Can I match a range from an array? by brassmon_k
in thread Can I match a range from an array? by brassmon_k

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.