172. Factorial Trailing Zeros
https://leetcode.com/problems/factorial-trailing-zeroes/submissions/
Problem
Given an integer n
, return the number of trailing zeroes in n!
.
Follow up: Could you write a solution that works in logarithmic time complexity?
Example 1:
Example 2:
Example 3:
Constraints:
1 <= n <= 104
Solution
#math
Last updated
Was this helpful?