Count Odd Digits

Write a function odd_digits(n)odd\_digits(n) that receives a non-negative integer nn and returns the number of occurrences of odd digits in nn.

Observation

All integers are assumed written in the usual base 10.

Problem information

Author: José Luis Balcázar

Generation: 2026-01-25T16:48:07.401Z

© Jutge.org, 2006–2026.
https://jutge.org