Javatpoint Logo
Javatpoint Logo

PHP gmp_divexact() Function

The GMP function is used to operate mathematical operations in a single line. The GMP divexact() function is created in PHP and utilized to check if a GMP number is exactly divisible by another GMP number. If the function is divisible, then the output shows the exact quotient. If the function is not divisible, then display numbers.

Syntax

The given syntax shows whether the parameter is divisible or not using a function.

Parameters

  • The function uses two parameters as a resource and shows value is divisible or not using the given function.

Return Value:

This function returns a numerical value to get whether the given parameter is divisible or not.

Examples

Example1: The given example shows whether a value is divisible or not. The parameter works on the positive or basic negative values.

Output:

PHP gmp_divexact() Function

Example2: The given example shows whether a value is divisible or not. The parameter works on the negative values.

Output:

PHP gmp_divexact() Function

Example3: The given example shows whether a value is divisible or not The parameter can use numerical value for the divisible function.

Output:

PHP gmp_divexact() Function

Example4: The given example shows the division function with the other GMP function.

Output:

PHP gmp_divexact() Function

Conclusion

The division "gmp_divexact()" function is used for division operation using GMP parameter. It gets the numerical data to get the value of the divisible function. We can get the data in a numerical format to know value is divisible or not divisible.







Youtube For Videos Join Our Youtube Channel: Join Now

Feedback


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA