title: How to read data that appear in next line?
body: <p>My problem is to read data in the next line for input 2 same like we can read data as input 1. I expect that we can read input 2 as input 1. </p>
  
  <p>Here is input 1:</p>
  
  <pre><code>A1 clkout n0 vss vss nx 0.408 0.02 $$UNI
  A2 clkout n2 vss vss nx 0.612 0.02 $$UNI
  A3 clkin  n1 vss vss nx 0.34 0.02 $$UNI
  </code></pre>
  
  <p>Here is input 2: </p>
  
  <pre><code>A1 clkout n0 vss vss nx
  + 0.408 0.02 $$UNI
  A2 clkout n2 vss vss nx 0.612  
  + 0.02 $$UNI
  A3 clkin  n1 vss vss
  + nx 0.34 0.02 $$UNI 
  </code></pre>
  
  <p>The code to get the 6th column is shown below:</p>
  
  <pre><code>while (&lt;SN&gt;) {
          chomp;
          next if (/^\$\s*\#+/);
  
          if (/^M/) {
  
              my @m = split (/\s+/, $_);
  
              if ($m[6] =~ /\=/) {
                  $m[6] = $m[7];
                 $m[6] =~ s/W\=(\S+)u/$2/;
  
              }
  
              $CSV{cell}{$c}{tx}{$m[5]}{count} += 1;
              $CSV{cell}{$c}{tx}{$m[5]}{totZ}  += $m[6];
  
              if ($opt_grid_um) { 
                 $g = $m[6] / $G{grid_um};
              } else {
                 $g = $m[6];
              }
         close (SN);
       }
  </code></pre>
  
  <p>I already tried to get data for the 6th column from input 1 but cannot read for input 2. I think there is some error at this line: <code>$m[6] =~ s/W\=(\S+)u/$2/;</code></p>
  
  <p>My expected result is to read input 2 format as input 1 by ignoring the '+' sign in front of the second line. Then, the script can read data in each column as input 1.</p>