I have 4 php files all of them is almost same only the table names are different and also the values in the arrays, I want to put all these values in one array in another php file.

this file is Germany.php 

```
foreach($array as $key => $val) {
    $Home=0;
    $Draw=0;
    $Away=0;
    $sql = "SELECT * FROM Germany where B = '{$val['B']}' AND E = '{$val['E']}' AND F = '{$val['F']}' AND O ='{$val['O']}' AND A = '*' ";
    $result = $conn->query($sql);
    if ($result->num_rows > 0) {
    $rowcount=mysqli_num_rows($result);
        // output data of each row 
        while($row = $result->fetch_assoc()) {
            if($row['R'] == 1){
                $Home++;
            }elseif($row['R'] == 0){
                $Draw++;
            }else{
                $Away++;
            }
        }

        //We use an array rather than overriding everytime
        $AwayPrediction[$key] = round(($Away/$rowcount )*100);
    } else {
        echo "0 results";
    }
}
$conn->close();

```

I think I have to do something like that in index.php

```
<table class="table">   
<thead> 
      <tr>
        <th>Home</th>
         <th>Away</th>
         <th>Result</th>
      </tr>
</thead>

    <?php

$array_of_teams=array();
        include 'germany.php';
        foreach($array as $key => $data) {
    $array_of_teams+=merge($AwayPrediction[$key]);
        echo "<tr>";
        echo "<td>".$data['H']."</td>";
        echo "<td>".$data['M']."</td>";

    echo "<td>".$AwayPrediction[$key]."</td>";
    }

include 'france.php';
foreach($array as $key => $data) {

    $array_of_teams+=merge($AwayPrediction[$key]);

echo "<tr>";
echo "<td>".$data['H']."</td>";
echo "<td>".$data['M']."</td>";

echo "<td>".$AwayPrediction[$key]."</td>";
}

```

How can I merge or add $AwayPrediction[$key] to $array\_of\_teams=array(); for each file ?