# shz_fmodf

Source: https://sh4zam.com/api/scalar/shz_fmodf/

> Replacement for the <math.h> routine, fmodf()

```c
SHZ_INLINE float shz_fmodf(float num, float denom) SHZ_NOEXCEPT;
```

Replacement for the \<math.h> routine, fmodf().

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `num` | `float` |  |
| `denom` | `float` |  |

## Returns

`float`

## Details

Returns the floating-point remainder of `num` divided by `denom`, rounded towards zero.

## Warnings

- This routine does not gracefully handle dividing by zero.

## Availability

- **C++ equivalent:** [`shz::fmodf`](https://sh4zam.com/api/cpp/#shzfmodf)
- **Type-generic form:** none
- **Back-ends:** SH4: shared C implementation · SW: portable C · SPU: shared C implementation
- **Defined in:** [`sh4zam/shz_scalar.h:137`](https://github.com/gyrovorbis/sh4zam/blob/ba1e30c88d49df0311870b229e1dd860ef26c477/include/sh4zam/shz_scalar.h#L137)
- **Module:** [Scalar](https://sh4zam.com/api/scalar/), section "Rounding"

## See also

[`shz_remainderf`](https://sh4zam.com/api/scalar/shz_remainderf/)
