I've faced problem that I cant resolve in my simple code 

```
foreach(file('num.txt') as $num) {
    foreach(file('char.txt') as $char) {

        echo $char.$num. "<br>";
        if($char=="C"&&$num==3){
            echo 'Found it<br>';
            break;
        }
    }
    echo '----------------------------<br>';

}

```

num.txt contains numbers like this
1
2
3
4
5 per line
char contains character Like A B C D per line
. 
and as result
it dose not remove the C3 in text step after break

but i want it like this way without the founded C3

```
A1
B1
C1
D1
--------------
A2
B2
C2
D2
--------------
A3
B3
C3
Found it
D3
--------------
A4
B4
D4
--------------
A5
B5
D5
--------------

```

so C is no longer in the loop and continue if add B5 and so on
Please help i need this assignment