title: Create and increment an array in Perl
body: <p>I have a problem with my array and I need your help.</p>
  
  <p>I want to create an array with the result given by my <code>if</code>, for comparison with an another array.</p>
  
  <pre><code>if (grep {$community eq $_ } @communities) {
     my $community_matchs = "";
     print "$community;$login;$last_at;;$size;1\n";
     push (@matchs, $community_matchs); 
     #my array
  }
  else{
     print "$community;$login;$last_at;;$size;0\n";
  }
  </code></pre>
  
  <p>Then, later on</p>
  
  <pre><code>if (grep {$c ne $_} @matchs) {
     print "$community;3\n";
  </code></pre>
  
  <p>I am a beginner and French, so be understanding with me.</p>