English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

Fonction fmod() en PHP

Lefmod()La fonction retourne le dividend/Le reste du diviseur. Le reste flottant dans fmod.

Syntaxe

fmod(dividende/ diviseur)

Paramètre

  • Dividende-le nombre à diviser.

  • Diviseur-C'estDiviseur.

retourne

Lefmod()La fonction retourne le diviseur/Le reste du diviseur.

Exemple

<?php
   $p = 30;
   $q = 9;
   $remainder = fmod($p, $q);
   echo $remainder;
?>

Résultat de sortie

3