How do I not see the one available in the column that is already not available, if I do it with @else it's worse since I go through the array 3 times.
<table>
<thead>
<tr>
<th>Hora</th>
<th>Fecha</th>
<th>Paciente</th>
<th>Status</th>
</tr>
</thead>
<tbody>
@foreach($a as $x)
<tr>
<td>{{$x}}</td>
@foreach($b as $z) @if($x == $z)
<td>14:00</td>
<td>Lopez</td>
<td>no disponible</td>
@endif @endfor
<td></td>
<td></td>
<td>disponible</td>
</tr>
@endforeach
</tbody>
</table>
Result:
Hora Fecha Paciente Status 10 disponible 12 disponible 13 14:00 Lopez no disponible disponible 14 14:00 Lopez no disponible disponible 15 disponible 16 disponible 17 disponible 18 14:00 Lopez no disponible disponible 19 disponible 20 disponible