# divisor_count function

How many positive divisors a whole number has.

## How to write it

### divisor_count(n)

**n**

A whole number. Takes a whole number.

## Examples

- $\displaystyle \operatorname{divisor\_count}(12) = 6$

  `divisor_count(12)`

  In the solver, `divisor_count(12)` gives `6`.

  [Open in the solver](https://hilberon.com/?q=divisor_count%2812%29)

## Related functions

- [divisor_sigma](https://hilberon.com/library/divisor_sigma)

  Sum of the powers of the divisors of a whole number.
- [divisor_sum](https://hilberon.com/library/divisor_sum)

  Sum of the positive divisors of a whole number.
- [discrete_log](https://hilberon.com/library/discrete_log)

  The exponent that takes a base to a value modulo a number.
- [convergents](https://hilberon.com/library/convergents)

  The convergents of a continued fraction.
- [divisors](https://hilberon.com/library/divisors)

  The positive divisors of a whole number, in increasing order.
- [continued_fraction](https://hilberon.com/library/continued_fraction)

  The continued fraction of a rational number, as a list.

---
Source: https://hilberon.com/library/divisor_count
