centrer la grille

This commit is contained in:
Adrien MALINGREY 2025-04-25 03:05:08 +02:00
parent dd8dabd39c
commit 967d5de46c
2 changed files with 3 additions and 3 deletions

View File

@ -45,8 +45,7 @@ function mots_espaces($longueur) {
fisherYatesShuffle($mots_de_n_lettres[$longueur]); fisherYatesShuffle($mots_de_n_lettres[$longueur]);
foreach($mots_de_n_lettres[$longueur] as $mot) { foreach($mots_de_n_lettres[$longueur] as $mot) {
yield $mot; yield $mot;
$nb_mots++; if (++$nb_mots > MAX_MOTS) {
if ($nb_mots > MAX_MOTS) {
return; return;
} }
} }
@ -60,7 +59,7 @@ function mots_espaces($longueur) {
yield "$mot2 $mot1"; yield "$mot2 $mot1";
$nb_mots += 2; $nb_mots += 2;
if ($nb_mots > MAX_MOTS) { if ($nb_mots > MAX_MOTS) {
break; return;
} }
} }
} }

View File

@ -97,6 +97,7 @@ $grille = new Grille($hauteur, $largeur, $id);
<?php endif; ?> <?php endif; ?>
</td> </td>
<?php endfor; ?> <?php endfor; ?>
<th></th>
</tr> </tr>
<?php endfor; ?> <?php endfor; ?>
</table> </table>